]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
only subtract file size if entry has been validated
authorwessels <>
Fri, 27 Mar 1998 11:45:21 +0000 (11:45 +0000)
committerwessels <>
Fri, 27 Mar 1998 11:45:21 +0000 (11:45 +0000)
src/store.cc

index e01b0f8df7cfea4113961f23de4c3d8dbad422b7..375dade411920faf21bc49523775f83f3ac24a44 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: store.cc,v 1.396 1998/03/20 18:06:47 rousskov Exp $
+ * $Id: store.cc,v 1.397 1998/03/27 04:45:21 wessels Exp $
  *
  * DEBUG: section 20    Storeage Manager
  * AUTHOR: Harvest Derived
@@ -721,7 +721,8 @@ storeRelease(StoreEntry * e)
     if (e->swap_file_number > -1) {
        storeUnlinkFileno(e->swap_file_number);
        if (e->swap_status == SWAPOUT_DONE)
-           storeDirUpdateSwapSize(e->swap_file_number, e->swap_file_sz, -1);
+           if (EBIT_TEST(e->flag, ENTRY_VALIDATED))
+               storeDirUpdateSwapSize(e->swap_file_number, e->swap_file_sz, -1);
        if (!EBIT_TEST(e->flag, KEY_PRIVATE))
            storeDirSwapLog(e, SWAP_LOG_DEL);
     }