--------------------- PatchSet 4162 Date: 2007/04/05 07:28:10 Author: amosjeffries Branch: squid3-ipv6 Tag: (none) Log: patch cleaning. rollback old conversion. Members: src/external_acl.cc:1.37.6.4->1.37.6.5 src/forward.cc:1.35.4.10->1.35.4.11 src/fqdncache.cc:1.9.2.8->1.9.2.9 Index: squid3/src/external_acl.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/external_acl.cc,v retrieving revision 1.37.6.4 retrieving revision 1.37.6.5 diff -u -r1.37.6.4 -r1.37.6.5 --- squid3/src/external_acl.cc 21 Mar 2007 08:55:12 -0000 1.37.6.4 +++ squid3/src/external_acl.cc 5 Apr 2007 07:28:10 -0000 1.37.6.5 @@ -1,6 +1,6 @@ /* - * $Id: external_acl.cc,v 1.37.6.4 2007/03/21 08:55:12 amosjeffries Exp $ + * $Id: external_acl.cc,v 1.37.6.5 2007/04/05 07:28:10 amosjeffries Exp $ * * DEBUG: section 82 External ACL * AUTHOR: Henrik Nordstrom, MARA Systems AB @@ -788,7 +788,7 @@ break; case _external_acl_format::EXT_ACL_MYADDR: - str = INET_NTOA(request->my_addr); + str = inet_ntoa(request->my_addr); break; case _external_acl_format::EXT_ACL_MYPORT: Index: squid3/src/forward.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/forward.cc,v retrieving revision 1.35.4.10 retrieving revision 1.35.4.11 diff -u -r1.35.4.10 -r1.35.4.11 --- squid3/src/forward.cc 21 Mar 2007 08:55:12 -0000 1.35.4.10 +++ squid3/src/forward.cc 5 Apr 2007 07:28:10 -0000 1.35.4.11 @@ -1,6 +1,6 @@ /* - * $Id: forward.cc,v 1.35.4.10 2007/03/21 08:55:12 amosjeffries Exp $ + * $Id: forward.cc,v 1.35.4.11 2007/04/05 07:28:10 amosjeffries Exp $ * * DEBUG: section 17 Request Forwarding * AUTHOR: Duane Wessels @@ -184,7 +184,7 @@ * be allowed. yuck, I know. */ - if (!ADDR_IS_NOADDR(request->client_addr) && request->protocol != PROTO_INTERNAL && request->protocol != PROTO_CACHEOBJ) { + if (request->client_addr.s_addr != no_addr.s_addr && request->protocol != PROTO_INTERNAL && request->protocol != PROTO_CACHEOBJ) { /* * Check if this host is allowed to fetch MISSES from us (miss_access) */ @@ -775,7 +775,7 @@ tos = getOutgoingTOS(request); debug(17, 3) ("fwdConnectStart: got addr %s, tos %d\n", - INET_NTOA(outgoing), tos); + inet_ntoa(outgoing), tos); fd = comm_openex(SOCK_STREAM, IPPROTO_TCP, Index: squid3/src/fqdncache.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/fqdncache.cc,v retrieving revision 1.9.2.8 retrieving revision 1.9.2.9 diff -u -r1.9.2.8 -r1.9.2.9 --- squid3/src/fqdncache.cc 23 Mar 2007 13:03:28 -0000 1.9.2.8 +++ squid3/src/fqdncache.cc 5 Apr 2007 07:28:11 -0000 1.9.2.9 @@ -1,6 +1,6 @@ /* - * $Id: fqdncache.cc,v 1.9.2.8 2007/03/23 13:03:28 amosjeffries Exp $ + * $Id: fqdncache.cc,v 1.9.2.9 2007/04/05 07:28:11 amosjeffries Exp $ * * DEBUG: section 35 FQDN Cache * AUTHOR: Harvest Derived @@ -547,7 +547,7 @@ const char * fqdncache_gethostbyaddr(struct IN_ADDR addr, int flags) { - char *name = (char *)INET_NTOA(addr); + char *name = inet_ntoa(addr); fqdncache_entry *f = NULL; struct IN_ADDR ip; @@ -579,7 +579,7 @@ /* check if it's already a FQDN address in text form. */ - if (!SAFE_INET_ADDR(name, &ip)) + if (!safe_inet_addr(name, &ip)) return name; FqdncacheStats.misses++; @@ -626,7 +626,7 @@ storeAppendPrintf(sentry, "FQDN Cache Contents:\n\n"); storeAppendPrintf(sentry, "%-45.45s %3s %3s %3s %s\n", - "Address", "Flg", "TTL", "Cnt", "Hostnames"); /* Let's get the maximum for 15 (IPv4) /45 (IPv6) */ + "Address", "Flg", "TTL", "Cnt", "Hostnames"); hash_first(fqdn_table); @@ -653,16 +653,16 @@ } const char * - fqdnFromAddr(struct IN_ADDR addr) { const char *n; - static char buf[MAXIPSTRLEN]; + static char buf[MAX_IPSTRLEN]; if (Config.onoff.log_fqdn && (n = fqdncache_gethostbyaddr(addr, 0))) return n; - xstrncpy(buf, INET_NTOA(addr), MAXIPSTRLEN); +/* FIXME INET6 : drop temp conversion */ IPAddress tmp(addr); + tmp.NtoA(buf, MAX_IPSTRLEN); return buf; }