--------------------- PatchSet 6443 Date: 2005/02/22 12:21:57 Author: oliv3 Branch: icap-2_5 Tag: (none) Log: Bugfix for RESPMOD when a request was aborted Members: src/store.c:1.16.6.2.2.4->1.16.6.2.2.5 Index: squid/src/store.c =================================================================== RCS file: /cvsroot/squid-sf//squid/src/store.c,v retrieving revision 1.16.6.2.2.4 retrieving revision 1.16.6.2.2.5 diff -u -r1.16.6.2.2.4 -r1.16.6.2.2.5 --- squid/src/store.c 4 Aug 2004 19:48:08 -0000 1.16.6.2.2.4 +++ squid/src/store.c 22 Feb 2005 12:21:57 -0000 1.16.6.2.2.5 @@ -1,6 +1,6 @@ /* - * $Id: store.c,v 1.16.6.2.2.4 2004/08/04 19:48:08 dwsquid Exp $ + * $Id: store.c,v 1.16.6.2.2.5 2005/02/22 12:21:57 oliv3 Exp $ * * DEBUG: section 20 Storage Manager * AUTHOR: Harvest Derived @@ -520,7 +520,16 @@ MemObject *mem = e->mem_obj; assert(mem != NULL); assert(len >= 0); - assert(e->store_status == STORE_PENDING); + debug(20, 3) ("storeAppend: '%s'\n", storeKeyText(e->hash.key)); + if (e->store_status != STORE_PENDING) { + /* + * if we're not STORE_PENDING, then probably we got aborted + * and there should be NO clients on this entry + */ + assert(EBIT_TEST(e->flags, ENTRY_ABORTED)); + assert(e->mem_obj->nclients == 0); + return; + } if (len) { debug(20, 5) ("storeAppend: appending %d bytes for '%s'\n", len,