From: Frederic Marchal Date: Wed, 4 Mar 2015 18:57:23 +0000 (+0100) Subject: Proxy authentication code is ignored when building the report X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fea96be4cb6351f9c1669863061b601268627c9a;p=thirdparty%2Fsarg.git Proxy authentication code is ignored when building the report The user report excludes HTTP code 407 meaning that the proxy requires an authentication. It must be excluded too when summing up the downloaded size while reading the input log. The previous code aborted with an error if --enable-extraprotection was used and the log contained a 407 code. --- diff --git a/log.c b/log.c index 9ad736f..1d4c48a 100644 --- a/log.c +++ b/log.c @@ -1478,8 +1478,10 @@ int main(int argc,char *argv[]) } } #ifdef ENABLE_DOUBLE_CHECK_DATA - ufile->user->nbytes+=nbytes; - ufile->user->elap+=elap_time; + if (strcmp(code,"TCP_DENIED/407")!=0) { + ufile->user->nbytes+=nbytes; + ufile->user->elap+=elap_time; + } #endif if (ufile->file==NULL) {