]> git.ipfire.org Git - thirdparty/sarg.git/blobdiff - siteuser.c
Append \n at the end of every debuga
[thirdparty/sarg.git] / siteuser.c
index b4f95d03f1c43257c3ab7b4b61f4b24afcea24bb..57ef6097b2165a48bbc79299a3bbed29831e5a13 100644 (file)
@@ -69,7 +69,7 @@ void siteuser(void)
    }
 
    if (!fgets(period,sizeof(period),fp_in)) {
-      debuga(_("(siteuser) read error in %s"),per);
+      debuga(_("(siteuser) read error in %s\n"),per);
       exit(1);
    }
    fclose(fp_in);
@@ -77,19 +77,19 @@ void siteuser(void)
    sprintf(csort,"sort -k 4,4 -k 1,1 -o \"%s\" \"%s\"",general2,general);
    cstatus=system(csort);
    if (!WIFEXITED(cstatus) || WEXITSTATUS(cstatus)) {
-      debuga(_("sort command return status %d"),WEXITSTATUS(cstatus));
-      debuga(_("sort command: %s"),csort);
+      debuga(_("sort command return status %d\n"),WEXITSTATUS(cstatus));
+      debuga(_("sort command: %s\n"),csort);
       exit(1);
    }
 
    if((fp_in=fopen(general2,"r"))==NULL) {
-     fprintf(stderr, "SARG: (topsite) %s: %s\n",_("Cannot open log file"),general2);
-     debuga(_("sort command: %s"),csort);
+     debuga(_("(topsite) Cannot open log file: %s\n"),general2);
+     debuga(_("sort command: %s\n"),csort);
      exit(1);
    }
 
    if((fp_ou=fopen(report,"w"))==NULL) {
-     fprintf(stderr, "SARG: (topsite) %s: %s\n",_("Cannot open log file"),report);
+     debuga(_("(topsite) Cannot open log file: %s\n"),report);
      exit(1);
    }
 
@@ -110,13 +110,13 @@ void siteuser(void)
    obytes=0;
 
    if((users=(char *) malloc(204800))==NULL){
-      fprintf(stderr, "SARG: ERROR: %s",_("Cannot load. Memory fault"));
+      debuga(_("ERROR: Cannot load. Memory fault\n"));
       exit(1);
    }
    strcpy(users," ");
 
    if (longline_prepare(&line)<0) {
-      debuga(_("Not enough memory to read file %s"),general2);
+      debuga(_("Not enough memory to read file %s\n"),general2);
       exit(1);
    }
 
@@ -125,7 +125,7 @@ void siteuser(void)
       if(item.total) continue;
       uinfo=userinfo_find_from_id(item.user);
       if (!uinfo) {
-         debuga(_("Unknown user ID %s in file %s"),item.user,general2);
+         debuga(_("Unknown user ID %s in file %s\n"),item.user,general2);
          exit(1);
       }
 
@@ -136,7 +136,7 @@ void siteuser(void)
             ourl_size=url_len+1;
             ourl=realloc(ourl,ourl_size);
             if (!ourl) {
-               debuga(_("Not enough memory to store the url"));
+               debuga(_("Not enough memory to store the url\n"));
                exit(1);
             }
          }
@@ -187,7 +187,7 @@ void siteuser(void)
             ourl_size=url_len+1;
             ourl=realloc(ourl,ourl_size);
             if (!ourl) {
-               debuga(_("Not enough memory to store the url"));
+               debuga(_("Not enough memory to store the url\n"));
                exit(1);
             }
          }