]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Henrik:
authorwessels <>
Sat, 16 May 1998 01:55:59 +0000 (01:55 +0000)
committerwessels <>
Sat, 16 May 1998 01:55:59 +0000 (01:55 +0000)
fix storeClientCopy copy-from-memory condition.   Require that copy_offset
be between LO and HI, not just that LO < HI.

src/store_client.cc

index 74ccc31bbadb9a285f41fe04db95c119750ebe21..86366c2244a460b889583720572cadd14288eb72 100644 (file)
@@ -175,7 +175,7 @@ storeClientCopy2(StoreEntry * e, store_client * sc)
     } else if (e->store_status == STORE_PENDING && sc->seen_offset == mem->inmem_hi) {
        /* client has already seen this, wait for more */
        debug(20, 3) ("storeClientCopy2: Waiting for more\n");
-    } else if (sc->copy_offset >= mem->inmem_lo && mem->inmem_lo < mem->inmem_hi) {
+    } else if (sc->copy_offset >= mem->inmem_lo && sc->copy_offset < mem->inmem_hi) {
        /* What the client wants is in memory */
        debug(20, 3) ("storeClientCopy2: Copying from memory\n");
        sz = stmemCopy(mem->data, sc->copy_offset, sc->copy_buf, sc->copy_size);