Sun Oct 17 01:39:04 CEST 1999 Modified Files in squid/src store.c store_rebuild.c Release unneeded store entries during cache rebuild. a) Entries for proxied objects during the rebuild (squid runs in proxy-only mode during the rebuild) b) Old entries replaced with a newer entry during the rebuild. ----------------------------------------------------------------- Index: squid/src/store.c diff -u squid/src/store.c:1.1.1.39.2.6 squid/src/store.c:1.1.1.39.2.7 --- squid/src/store.c:1.1.1.39.2.6 Sun Oct 17 01:24:34 1999 +++ squid/src/store.c Sun Oct 17 01:39:03 1999 @@ -800,12 +800,16 @@ storeSetMemStatus(e, NOT_IN_MEMORY); destroy_MemObject(e); } - /* - * Fake a call to storeLockObject(). When rebuilding is done, - * we'll just call storeUnlockObject() on these. - */ - e->lock_count++; - stackPush(&LateReleaseStack, e); + if (e->swap_file_number > -1) { + /* + * Fake a call to storeLockObject(). When rebuilding is done, + * we'll just call storeUnlockObject() on these. + */ + e->lock_count++; + stackPush(&LateReleaseStack, e); + } else { + destroy_StoreEntry(e); + } return; } storeLog(STORE_LOG_RELEASE, e); Index: squid/src/store_rebuild.c diff -u squid/src/store_rebuild.c:1.1.1.18.2.1 squid/src/store_rebuild.c:1.1.1.18.2.2 --- squid/src/store_rebuild.c:1.1.1.18.2.1 Tue Jul 13 02:11:56 1999 +++ squid/src/store_rebuild.c Sun Oct 17 01:39:04 1999 @@ -285,6 +285,7 @@ storeDirMapBitReset(e->swap_file_number); e->swap_file_number = -1; } + storeRelease(e); RebuildState.objcount--; RebuildState.cancelcount++; }