diff -uNrw squid-3.2.0.18/src/enums.h squid-3.2.0.18.n/src/enums.h
--- squid-3.2.0.18/src/enums.h	2012-07-11 06:06:31.000000000 +0400
+++ squid-3.2.0.18.n/src/enums.h	2012-07-17 18:30:51.294883979 +0400
@@ -160,7 +160,8 @@
     ENTRY_NEGCACHED,
     ENTRY_VALIDATED,
     ENTRY_BAD_LENGTH,
-    ENTRY_ABORTED
+    ENTRY_ABORTED,
+    ENTRY_PERSIST
 };
 
 /*
diff -uNrw squid-3.2.0.18/src/store.cc squid-3.2.0.18.n/src/store.cc
--- squid-3.2.0.18/src/store.cc	2012-07-11 06:06:31.000000000 +0400
+++ squid-3.2.0.18.n/src/store.cc	2012-07-17 18:34:33.262681496 +0400
@@ -769,12 +769,18 @@
             }
 
 #endif
-            pe->replaceHttpReply(rep);
+            pe->replaceHttpReply(rep, false);
 
             pe->timestampsSet();
 
             pe->makePublic();
 
+            EBIT_SET(pe->flags, ENTRY_PERSIST);
+
+            pe->startWriting();
+
+            EBIT_CLR(pe->flags, ENTRY_PERSIST);
+
             pe->complete();
 
             pe->unlock();
@@ -1900,6 +1906,9 @@
     if (EBIT_TEST(flags, ENTRY_SPECIAL))
         return; // cannot trim because we do not load them again
 
+    if (EBIT_TEST(flags, ENTRY_PERSIST))
+        return; // cannot trim because we asked not to do that
+
     if (!preserveSwappable) {
         if (mem_obj->policyLowestOffsetToKeep(0) == 0) {
             /* Nothing to do */

