]> git.ipfire.org Git - thirdparty/sarg.git/blobdiff - repday.c
Don't generate the date/time report page if it isn't used
[thirdparty/sarg.git] / repday.c
index 712cfcce94997be03dda2df982d812092b6bec6b..af8e8f9516322f6e556ec019e2ed33159b555176 100644 (file)
--- a/repday.c
+++ b/repday.c
@@ -57,6 +57,7 @@ void report_day(const struct userinfostruct *uinfo)
        struct getwordstruct gwarea;
        struct tm t;
 
+       if (datetimeby==0) return;
        snprintf(wdirname,sizeof(wdirname),"%s/%s.day",tmp,uinfo->filename);
        if(access(wdirname, R_OK) != 0) return;
 
@@ -119,7 +120,7 @@ void report_day(const struct userinfostruct *uinfo)
        fclose(fp_in);
 
        if((fp_ou=fopen(arqout,"w"))==NULL) {
-               debuga(_("(repday) Cannot open log file %s: %s\n"),arqout,strerror(errno));
+               debuga(_("(repday) Cannot open output file %s: %s\n"),arqout,strerror(errno));
                exit(EXIT_FAILURE);
        }