--------------------- PatchSet 6478 Date: 2008/01/10 08:00:17 Author: amosjeffries Branch: squid3-ipv6 Tag: (none) Log: Debug assert logics in CNAME merging caused squid to crash. Members: src/ipcache.cc:1.9.2.55->1.9.2.56 Index: squid3/src/ipcache.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/ipcache.cc,v retrieving revision 1.9.2.55 retrieving revision 1.9.2.56 diff -u -r1.9.2.55 -r1.9.2.56 --- squid3/src/ipcache.cc 9 Jan 2008 04:59:19 -0000 1.9.2.55 +++ squid3/src/ipcache.cc 10 Jan 2008 08:00:17 -0000 1.9.2.56 @@ -1,6 +1,6 @@ /* - * $Id: ipcache.cc,v 1.9.2.55 2008/01/09 04:59:19 amosjeffries Exp $ + * $Id: ipcache.cc,v 1.9.2.56 2008/01/10 08:00:17 amosjeffries Exp $ * * DEBUG: section 14 IP Cache * AUTHOR: Harvest Derived @@ -878,8 +878,8 @@ \param outlen Size of list out */ void -ipcacheMergeIPLists(const IPAddress *aaddrs, int alen, - const IPAddress *baddrs, int blen, +ipcacheMergeIPLists(const IPAddress *aaddrs, const int alen, + const IPAddress *baddrs, const int blen, IPAddress **out, int &outlen ) { int fc=0, t=0, c=0; @@ -1034,7 +1034,7 @@ i->addrs.in_addrs = NULL; ipcacheMergeIPLists(tmpbuf, pcount, addrs->in_addrs, ccount, &(i->addrs.in_addrs), fc); debugs(14,8, HERE << "in=" << tmpbuf << ", out=" << i->addrs.in_addrs ); - assert(tmpbuf); + assert( (pcount>0 ? tmpbuf!=NULL : tmpbuf==NULL) ); safe_free(tmpbuf); if( pcount > 0) {