From: Alex Rousskov Date: Tue, 8 Feb 2011 01:53:13 +0000 (-0700) Subject: Do not add in-transit store entries to the already overflowing memory cache. X-Git-Tag: take02~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=467261085527a6552a0b28f18c6579e616c44782;p=thirdparty%2Fsquid.git Do not add in-transit store entries to the already overflowing memory cache. --- diff --git a/src/store.cc b/src/store.cc index e21f77d1e5..7800e461d6 100644 --- a/src/store.cc +++ b/src/store.cc @@ -1439,6 +1439,10 @@ StoreEntry::keepInMemory() const if (!Config.onoff.memory_cache_first && swap_status == SWAPOUT_DONE && refcount == 1) return 0; + // already kept more than allowed + if (mem_node::InUseCount() > store_pages_max) + return 0; + return 1; }