]> git.ipfire.org Git - thirdparty/sarg.git/commitdiff
Editor removed trailing spaces
authorFrédéric Marchal <fmarchal@users.sourceforge.net>
Sun, 26 Aug 2012 13:39:53 +0000 (15:39 +0200)
committerFrédéric Marchal <fmarchal@users.sourceforge.net>
Sun, 26 Aug 2012 14:00:16 +0000 (16:00 +0200)
No change in the program. Only those files are affected. Other files may
get changed in the future.

readlog.c
readlog_sarg.c

index fcd51718189ddb3c5c5f0c2c207f51db4ea01e21..1543de4bf72a0abcfd8aa35fb9d4de84e0a0a95c 100644 (file)
--- a/readlog.c
+++ b/readlog.c
@@ -145,7 +145,7 @@ int ReadLogFile(struct ReadLogDataStruct *Filter)
                debuga(_("Not enough memory to read a log file\n"));
                exit(EXIT_FAILURE);
        }
-               
+
        for (iarq=0 ; iarq<NAccessLog ; iarq++) {
                arq=AccessLog[iarq];
 
@@ -252,7 +252,7 @@ int ReadLogFile(struct ReadLogDataStruct *Filter)
                                fflush (stdout);
                                OutputNonZero = REPORT_EVERY_X_LINES ;
                        }
-                       
+
                        /*
                        The following checks are retained here as I don't know to
                        what format they apply. They date back to pre 2.4 versions.
@@ -291,7 +291,7 @@ int ReadLogFile(struct ReadLogDataStruct *Filter)
                        if (current_format) {
                                log_entry_status=current_format->ReadEntry(linebuf,&log_entry);
                        }
-                       
+
                        // find out what line format to use
                        if (log_entry_status==RLRC_Unknown) {
                                x=-1;
@@ -808,7 +808,7 @@ int ReadLogFile(struct ReadLogDataStruct *Filter)
                                continue;
 
                        if (log_entry.DataSize<0) log_entry.DataSize=0;
-                       
+
                        if (log_entry.ElapsedTime<0) log_entry.ElapsedTime=0;
                        if (Filter->max_elapsed>0 && log_entry.ElapsedTime>Filter->max_elapsed) {
                                log_entry.ElapsedTime=0;
@@ -955,7 +955,7 @@ int ReadLogFile(struct ReadLogDataStruct *Filter)
                char end_hour[128];
                char val2[40];
                char val4[255];//val4 must not be bigger than arq_log without fixing the strcpy below
-               
+
                fclose(fp_log);
                safe_strcpy(end_hour,tbuf2,sizeof(end_hour));
                strftime(val2,sizeof(val2),"%d%m%Y",&period.start);
@@ -988,7 +988,7 @@ int ReadLogFile(struct ReadLogDataStruct *Filter)
                }
                if(debug)
                        debuga(_("Sarg parsed log saved as %s\n"),arq_log);
-       }       
+       }
 
        denied_close();
        authfail_close();
index b00dfe8712473391625e3886bf7fbf327c408cc8..ed93dfce6a2b5ec01097fa4ecf517f60ca1c3467 100644 (file)
@@ -61,13 +61,13 @@ static enum ReadLogReturnCodeEnum Sarg_ReadEntry(char *Line,struct ReadLogStruct
        int Hour;
        int Minute;
        int Second;
-       
+
        if (strncmp(Line,"*** SARG Log ***",16)==0) {
                InSargLog=true;
                return(RLRC_Ignore);
        }
        if (!InSargLog) return(RLRC_Unknown);
-       
+
        // get the date
        Day=0;
        while (isdigit(*Line)) Day=Day*10+(*Line++-'0');
@@ -83,7 +83,7 @@ static enum ReadLogReturnCodeEnum Sarg_ReadEntry(char *Line,struct ReadLogStruct
        Year=0;
        while (isdigit(*Line)) Year=Year*10+(*Line++-'0');
        if (*Line!='\t' || Year<1900 || Year>2200) return(RLRC_Unknown);
-       
+
        // get the time
        ++Line;
        Hour=0;
@@ -110,7 +110,7 @@ static enum ReadLogReturnCodeEnum Sarg_ReadEntry(char *Line,struct ReadLogStruct
        Entry->User=++Line;
        for (UserLen=0 ; *Line && *Line!='\t' ; UserLen++) Line++;
        if (*Line!='\t' || UserLen==0) return(RLRC_Unknown);
-       
+
        // get IP address
        Entry->Ip=++Line;
        for (IpLen=0 ; *Line && *Line!='\t' ; IpLen++) Line++;
@@ -120,13 +120,13 @@ static enum ReadLogReturnCodeEnum Sarg_ReadEntry(char *Line,struct ReadLogStruct
        Entry->Url=++Line;
        for (UrlLen=0 ; *Line && *Line!='\t' ; UrlLen++) Line++;
        if (*Line!='\t' || UrlLen==0) return(RLRC_Unknown);
-       
+
        // get the number of transfered bytes.
        Begin=++Line;
        Entry->DataSize=0LL;
        while (isdigit(*Line)) Entry->DataSize=Entry->DataSize*10+(*Line++-'0');
        if (*Line!='\t' || Begin==Line) return(RLRC_Unknown);
-       
+
        // get the HTTP code.
        Entry->HttpCode=++Line;
        for (HttpCodeLen=0 ; *Line && *Line!='\t' ; HttpCodeLen++) Line++;
@@ -152,7 +152,7 @@ static enum ReadLogReturnCodeEnum Sarg_ReadEntry(char *Line,struct ReadLogStruct
        Entry->HttpCode[HttpCodeLen]='\0';
        Entry->Url[UrlLen]='\0';
        Entry->User[UserLen]='\0';
-       
+
        return(RLRC_NoError);
 }