[master] adbff32 Fix an off by quite a lot error which neutered most of the good predictive vary could do.

Poul-Henning Kamp phk at varnish-cache.org
Mon Sep 3 10:39:12 CEST 2012


commit adbff32298bb8992e62eeebe8dfaa984c061294d
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Mon Sep 3 08:38:52 2012 +0000

    Fix an off by quite a lot error which neutered most of the good
    predictive vary could do.

diff --git a/bin/varnishd/cache/cache_vary.c b/bin/varnishd/cache/cache_vary.c
index bf6537f..5f508d2 100644
--- a/bin/varnishd/cache/cache_vary.c
+++ b/bin/varnishd/cache/cache_vary.c
@@ -261,7 +261,7 @@ VRY_Match(struct req *req, const uint8_t *vary)
 			vsp[ln + 1] = 0xff;
 			vsp[ln + 2] = 0;
 			VRY_Validate(vsp);
-			req->vary_l = vsp + 3;
+			req->vary_l = vsp + ln + 3;
 
 			i = vry_cmp(vary, vsp);
 			assert(i == 0 || i == 2);



More information about the varnish-commit mailing list