]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
- Added assertion to double check the end of clean logs
authorrousskov <>
Wed, 1 Apr 1998 14:25:47 +0000 (14:25 +0000)
committerrousskov <>
Wed, 1 Apr 1998 14:25:47 +0000 (14:25 +0000)
src/test_cache_digest.cc

index 8966decb8325d682e727d04b7f9ee16d08dcd91b..efb0924e9ddbc918f489322cbfc1ecb3e3b95697 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: test_cache_digest.cc,v 1.11 1998/04/01 07:14:06 rousskov Exp $
+ * $Id: test_cache_digest.cc,v 1.12 1998/04/01 07:25:47 rousskov Exp $
  *
  * AUTHOR: Alex Rousskov
  *
@@ -542,12 +542,11 @@ main(int argc, char *argv[])
        FileIterator *fi = fis[i];
        while (fi->inner_time > 0) {
            ready_time = fi->inner_time;
-           if (((storeSwapLogData*)fi->entry)->op != SWAP_LOG_ADD) {
+           if (((storeSwapLogData*)fi->entry)->op == SWAP_LOG_DEL)
                break;
-           } else {
-               cacheStore(them, fi->entry, 0);
-               fileIteratorAdvance(fi);
-           }
+           assert(((storeSwapLogData*)fi->entry)->op == SWAP_LOG_ADD);
+           cacheStore(them, fi->entry, 0);
+           fileIteratorAdvance(fi);
        }
     }
     /* digest peer cache content */