--------------------- PatchSet 7744 Date: 2006/05/14 05:42:21 Author: swsf Branch: epoll-2_5 Tag: (none) Log: Fix an error condition that can cause an assert when looking at the cache object lists in cachemgr. Members: src/forward.c:1.13.6.13.4.8->1.13.6.13.4.9 Index: squid/src/forward.c =================================================================== RCS file: /cvsroot/squid-sf//squid/src/forward.c,v retrieving revision 1.13.6.13.4.8 retrieving revision 1.13.6.13.4.9 diff -u -r1.13.6.13.4.8 -r1.13.6.13.4.9 --- squid/src/forward.c 16 Mar 2006 23:59:12 -0000 1.13.6.13.4.8 +++ squid/src/forward.c 14 May 2006 05:42:21 -0000 1.13.6.13.4.9 @@ -1,6 +1,6 @@ /* - * $Id: forward.c,v 1.13.6.13.4.8 2006/03/16 23:59:12 swsf Exp $ + * $Id: forward.c,v 1.13.6.13.4.9 2006/05/14 05:42:21 swsf Exp $ * * DEBUG: section 17 Request Forwarding * AUTHOR: Duane Wessels @@ -696,7 +696,7 @@ * is disk clients pending on a too large object being fetched and a * few other corner cases. */ - if (mem->inmem_hi - mem->inmem_lo > SM_PAGE_SIZE + Config.Store.maxInMemObjSize + READ_AHEAD_GAP) { + if (fd >= 0 && mem->inmem_hi - mem->inmem_lo > SM_PAGE_SIZE + Config.Store.maxInMemObjSize + READ_AHEAD_GAP) { EBIT_SET(e->flags, ENTRY_DEFER_READ); #if HAVE_EPOLL mem->serverfd=fd; @@ -705,7 +705,7 @@ return 1; } } - if (mem->inmem_hi - storeLowestMemReaderOffset(e) > READ_AHEAD_GAP) { + if (fd >= 0 && mem->inmem_hi - storeLowestMemReaderOffset(e) > READ_AHEAD_GAP) { EBIT_SET(e->flags, ENTRY_DEFER_READ); #if HAVE_EPOLL mem->serverfd=fd;