]> git.ipfire.org Git - thirdparty/sarg.git/blobdiff - redirector.c
Strip suffix length is a global variable
[thirdparty/sarg.git] / redirector.c
index e7b89e0ab3ebea9d188da458d1699600b1ff8ee1..abd1fae5640f5d3ae11a7aea3cb84ba19ad65607 100644 (file)
@@ -34,10 +34,9 @@ static int nfiles_done = 0;
 static int RedirectorErrors=0;
 //! The file containing the sorted entries.
 static char redirector_sorted[MAXLEN]="";
-//! Length of the suffix to strip from the user name.
-static int StripSuffixLen;
 
 extern char StripUserSuffix[MAX_USER_LEN];
+extern int StripSuffixLen;
 
 static void parse_log(FILE *fp_ou,char *buf,int dfrom,int duntil)
 {
@@ -283,7 +282,6 @@ static void read_log(const char *wentp, FILE *fp_ou,int dfrom,int duntil)
                debuga(__FILE__,__LINE__,_("Not enough memory to read file \"%s\"\n"),wentp);
                exit(EXIT_FAILURE);
        }
-       StripSuffixLen=strlen(StripUserSuffix);
 
        while ((buf=longline_read(fp_in,line)) != NULL) {
                parse_log(fp_ou,buf,dfrom,duntil);