fix misleading indentation

Mostly to shut up the compiler, but some real bugs hidden in there.
This commit is contained in:
Patrick Georgi
2025-12-09 21:21:13 +01:00
parent dca08bc5c2
commit ae001c320f
26 changed files with 243 additions and 135 deletions
+2 -1
View File
@@ -339,7 +339,7 @@ void AliasListUiItem::handleChangeButtonPress()
XmNvalue, &value_str,
NULL);
if(key_str != NULL)
if(key_str != NULL) {
if(strlen(key_str) > 0)
{
@@ -378,6 +378,7 @@ void AliasListUiItem::handleChangeButtonPress()
TRUE);
}
props_changed = TRUE;
}
}
}
///////////////////////////////////////////////////////////
@@ -295,7 +295,7 @@ void AlternatesListUiItem::handleChangeButtonPress()
XmNvalue, &test_str,
NULL);
if(test_str != NULL)
if(test_str != NULL) {
if(strlen(test_str) > 1)
{
@@ -323,6 +323,7 @@ void AlternatesListUiItem::handleChangeButtonPress()
TRUE);
}
props_changed = TRUE;
}
}
}
///////////////////////////////////////////////////////////
@@ -275,7 +275,7 @@ void IgnoreListUiItem::handleChangeButtonPress()
XmNvalue, &test_str,
NULL);
if(test_str != NULL)
if(test_str != NULL) {
if(strlen(test_str) > 1)
{
@@ -304,6 +304,7 @@ void IgnoreListUiItem::handleChangeButtonPress()
TRUE);
}
props_changed = TRUE;
}
}
}
///////////////////////////////////////////////////////////
+13 -13
View File
@@ -5459,23 +5459,23 @@ Widget parent=NULL;
}
if(!parent)
parent = theApplication->baseWidget();
DtMailGenDialog *genDialog = new DtMailGenDialog("Dialog",parent,XmDIALOG_FULL_APPLICATION_MODAL);
DtMailGenDialog *genDialog = new DtMailGenDialog("Dialog",parent,XmDIALOG_FULL_APPLICATION_MODAL);
char *errMsg = (char *) XtCalloc(1,10240+strlen(fsname));
char *errMsg = (char *) XtCalloc(1,10240+strlen(fsname));
// Serious error here -- No Space on Filesystem --
sprintf(errMsg,"Insufficient space on %s filesystem. Dtmail unable to show any new \n messages, delete messages, or save further changes to the open \n mailbox. Please contact your System Administrator to correct the \n filesystem space problem.",fsname);
free(fsname);
genDialog->setToErrorDialog(
CATGETS(DT_catd, 1, 6, "Mailer"),
errMsg);
XtFree(errMsg);
// Serious error here -- No Space on Filesystem --
sprintf(errMsg,"Insufficient space on %s filesystem. Dtmail unable to show any new \n messages, delete messages, or save further changes to the open \n mailbox. Please contact your System Administrator to correct the \n filesystem space problem.",fsname);
free(fsname);
genDialog->setToErrorDialog(
CATGETS(DT_catd, 1, 6, "Mailer"),
errMsg);
XtFree(errMsg);
genDialog->post_and_return(
CATGETS(DT_catd, 3, 9, "OK"),
NULL);
delete genDialog;
genDialog->post_and_return(
CATGETS(DT_catd, 3, 9, "OK"),
NULL);
delete genDialog;
}
void
RoamMenuWindow::stopAutoSave(void)
@@ -1875,7 +1875,7 @@ RFCMailBox::mapFile(DtMailEnv & error,
DEBUG_PRINTF(
("mapFile: Error mmap(1) == %p, errno = %d\n", map->map_region, errno));
if (_errorLogging)
if (_errorLogging) {
writeToDumpFile(
mmap_format_string,
pname, err_phase,
@@ -1885,6 +1885,7 @@ RFCMailBox::mapFile(DtMailEnv & error,
"%s(%d): statbuf: ino=%d, dev=%d, nlink=%d, size=%ld\n",
pname, err_phase,
statbuf.st_ino, statbuf.st_dev, statbuf.st_nlink, statbuf.st_size);
}
if (map->map_region == (char *) -1)
{
@@ -2030,7 +2031,7 @@ RFCMailBox::mapFile(DtMailEnv & error,
(map->map_region[offset_from_map+map->file_size-1] == '\0'))
) {
if (_errorLogging)
if (_errorLogging) {
writeToDumpFile(
"%s(%d): SafeRead(%d(%s), 0x%08lx, %d) == %d, errno == %d\n",
pname, err_phase, _fd, _real_path, map->map_region, bytesToRead,
@@ -2039,6 +2040,7 @@ RFCMailBox::mapFile(DtMailEnv & error,
"%s(%d): stat buf: ino=%d, dev=%d, nlink=%d, size=%ld\n",
pname, err_phase, statbuf.st_ino, statbuf.st_dev,
statbuf.st_nlink, statbuf.st_size);
}
if (readResults > 0) {
if (_errorLogging)