]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
DW:
authorwessels <>
Mon, 29 May 2000 09:10:39 +0000 (09:10 +0000)
committerwessels <>
Mon, 29 May 2000 09:10:39 +0000 (09:10 +0000)
 - Running the current code on an older 2.4 cache results in unlink
   errors.  During 2.4 development, we changed the way swap file
   numbers are assigned and stored.  The high 16 bits used to encode
   the SD index number.  There used to be a call to storeDirProperFileno
   here that re-assigned the index bits.  Now, for backwards
   compatibility, we just need to mask it off.

src/fs/diskd/store_dir_diskd.cc
src/fs/ufs/store_dir_ufs.cc

index 5477e18e712368a772c1fadb4bc47a3bc329e628..6e737d7a9b637bab95c88ebac096fd8658f5fe17 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: store_dir_diskd.cc,v 1.9 2000/05/29 01:53:58 wessels Exp $
+ * $Id: store_dir_diskd.cc,v 1.10 2000/05/29 03:10:39 wessels Exp $
  *
  * DEBUG: section 47    Store Directory Routines
  * AUTHOR: Duane Wessels
@@ -686,6 +686,15 @@ storeDiskdDirRebuildFromSwapLog(void *data)
            continue;
        if (s.op >= SWAP_LOG_MAX)
            continue;
+       /*
+        * BC: during 2.4 development, we changed the way swap file
+        * numbers are assigned and stored.  The high 16 bits used
+        * to encode the SD index number.  There used to be a call
+        * to storeDirProperFileno here that re-assigned the index
+        * bits.  Now, for backwards compatibility, we just need
+        * to mask it off.
+        */
+       s.swap_filen &= 0x00FFFFFF;
        debug(20, 3) ("storeDiskdDirRebuildFromSwapLog: %s %s %08X\n",
            swap_log_op_str[(int) s.op],
            storeKeyText(s.key),
index 9c7db81b00a58cbbd95627c8435933ca432613c6..659528f5e7960eaa0c904a90b66b9c713043bc92 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: store_dir_ufs.cc,v 1.3 2000/05/29 01:54:02 wessels Exp $
+ * $Id: store_dir_ufs.cc,v 1.4 2000/05/29 03:10:42 wessels Exp $
  *
  * DEBUG: section 47    Store Directory Routines
  * AUTHOR: Duane Wessels
@@ -537,6 +537,15 @@ storeUfsDirRebuildFromSwapLog(void *data)
            continue;
        if (s.op >= SWAP_LOG_MAX)
            continue;
+       /*
+        * BC: during 2.4 development, we changed the way swap file
+        * numbers are assigned and stored.  The high 16 bits used
+        * to encode the SD index number.  There used to be a call
+        * to storeDirProperFileno here that re-assigned the index 
+        * bits.  Now, for backwards compatibility, we just need
+        * to mask it off.
+        */
+       s.swap_filen &= 0x00FFFFFF;
        debug(20, 3) ("storeUfsDirRebuildFromSwapLog: %s %s %08X\n",
            swap_log_op_str[(int) s.op],
            storeKeyText(s.key),