Re: [squid-users] SARG question

From: Joost de Heer <sanguis@dont-contact.us>
Date: Mon, 21 Nov 2005 16:03:15 +0100 (CET)

Colin Farley wrote:
> I've had problems with the latest versions of SARG, I have only tested or
> BSD boxes but I would suggest trying 2.0.6. Unfotunately I don't use the
> -p switch so I can't say for sure if this is your problem.

I somewhat fixed this by patching fixip() in util.c, adding a check to see
if the ip string is only digits or ., and returning 0.0.0.0 if this isn't
the case:

   for (i=0;i<strlen(ip);i++) {
       if (ip[i]!='.' && (ip[i]<'0' || ip[i]>'9'))
       sprintf(ip,"0.0.0.0");
       return;
   }

But that's a workaround of course.

The line that seems to have triggered this behaviour (I added recs2 to the
output string in log.c):

1132208375.045 179621 10.224.26.198 TCP_MISS/504 1314 GET
http://61.139.33.188:8083/images/mini_con19.gif maggie NONE/- text/html

Looks to me that this line is in the proper format....

Joost
Received on Mon Nov 21 2005 - 08:03:24 MST

This archive was generated by hypermail pre-2.1.9 : Thu Dec 01 2005 - 12:00:10 MST