Re: squid3-ipv6 squid3/src ACLIP.cc,1.8.2.45,1.8.2.46

From: Amos Jeffries <squid3@dont-contact.us>
Date: Fri, 28 Sep 2007 09:01:15 +1200 (NZST)

> Both look strange to me. Shouldn't that be an ==
>

No, IPAddress can be assigned a string. It will try to do an inet_a/pton()
conversion. It returns true/false depending on whether the string was able
to be converted.

I'll add a note to clean it up.

>
> On tor, 2007-09-27 at 11:28 +0200, Rafael Martinez (Squid development)
> wrote:
>> Amos, a little typo:
>>
>> Acording to original semantics of safe_inet_addr, I think the conditioal
>> expresion must be positive
>>
>> SHOULD BE :
>>
>> > /* dotted notation */
>> > if (mask = asc)
>> > return true;
>> >
>>
>> Otherwise, acl all src 0.0.0.0 fails to parse....
>> Up to you the fix.
>>

Quite right. Thanks Rafael

Amos

>> > Index: ACLIP.cc
>> > ===================================================================
>> > RCS file: /cvsroot/squid/squid3/src/ACLIP.cc,v
>> > retrieving revision 1.8.2.45
>> > retrieving revision 1.8.2.46
>> > diff -C2 -d -r1.8.2.45 -r1.8.2.46
>> > *** ACLIP.cc 21 Sep 2007 12:34:14 -0000 1.8.2.45
>> > --- ACLIP.cc 24 Sep 2007 02:15:47 -0000 1.8.2.46
>> > ***************
>> > *** 205,209 ****
>> >
>> > /* dotted notation */
>> > ! if (safe_inet_addr(asc, mask))
>> > return true;
>> >
>> > --- 205,209 ----
>> >
>> > /* dotted notation */
>> > ! if (!(mask = asc))
>> > return true;
>> >
>> >
>
Received on Thu Sep 27 2007 - 15:01:36 MDT

This archive was generated by hypermail pre-2.1.9 : Mon Oct 01 2007 - 12:00:05 MDT