X-Git-Url: https://git.exim.org/users/jgh/exim.git/blobdiff_plain/55b583f6c31af475f329da97cd160a8ab2e8df8c..cab0c27721a3c1f3a146e44bcc6462eefb9eb9e7:/src/src/spool_mbox.c diff --git a/src/src/spool_mbox.c b/src/src/spool_mbox.c index de5830d64..432634094 100644 --- a/src/src/spool_mbox.c +++ b/src/src/spool_mbox.c @@ -216,8 +216,7 @@ if (spool_mbox_ok && !no_mbox_unspool) mbox_path = string_sprintf("%s/scan/%s", spool_directory, spooled_message_id); - tempdir = opendir(CS mbox_path); - if (!tempdir) + if (!(tempdir = opendir(CS mbox_path))) { debug_printf("Unable to opendir(%s): %s\n", mbox_path, strerror(errno)); /* Just in case we still can: */ @@ -225,7 +224,7 @@ if (spool_mbox_ok && !no_mbox_unspool) return; } /* loop thru dir & delete entries */ - while((entry = readdir(tempdir)) != NULL) + while((entry = readdir(tempdir))) { uschar *name = US entry->d_name; int dummy; @@ -233,7 +232,7 @@ if (spool_mbox_ok && !no_mbox_unspool) file_path = string_sprintf("%s/%s", mbox_path, name); debug_printf("unspool_mbox(): unlinking '%s'\n", file_path); - dummy = unlink(CS file_path); + dummy = unlink(CS file_path); dummy = dummy; /* compiler quietening */ } closedir(tempdir);