]> git.ipfire.org Git - thirdparty/sarg.git/commitdiff
Report a warning if the temporary file cannot be deleted.
authorFrédéric Marchal <fmarchal@users.sourceforge.net>
Sat, 18 Sep 2010 12:33:37 +0000 (12:33 +0000)
committerFrédéric Marchal <fmarchal@users.sourceforge.net>
Sat, 18 Sep 2010 12:33:37 +0000 (12:33 +0000)
denied.c

index 99a624f039f144bb2dad212d50f13227ef3799a3..70a83e53a8c1132ba4c520a9265e9a3bdec6ad17 100644 (file)
--- a/denied.c
+++ b/denied.c
@@ -163,7 +163,8 @@ void gen_denied_report(void)
    if (fclose(fp_ou)<0)
       debuga(_("Failed to close file %s - %s\n"),report,strerror(errno));
 
-   unlink(denied_in);
+   if (unlink(denied_in)==-1)
+      debuga(_("Failed to delete the file \"%s\" after processing it - %s\n"),denied_in,strerror(errno));
 
    return;
 }