[master] 80ee073 Take a stab at #1341

Poul-Henning Kamp phk at varnish-cache.org
Mon Sep 16 11:26:05 CEST 2013


commit 80ee0738ac7441d09a2e822a24bef87c24b9e8ea
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Mon Sep 16 09:25:46 2013 +0000

    Take a stab at #1341

diff --git a/bin/varnishd/cache/cache_busyobj.c b/bin/varnishd/cache/cache_busyobj.c
index ca721b7..8f49b20 100644
--- a/bin/varnishd/cache/cache_busyobj.c
+++ b/bin/varnishd/cache/cache_busyobj.c
@@ -228,7 +228,8 @@ ssize_t
 VBO_waitlen(struct busyobj *bo, ssize_t l)
 {
 	Lck_Lock(&bo->mtx);
-	assert(l <= bo->fetch_obj->len);
+	if (bo->state <= BOS_FINISHED)
+		assert(l <= bo->fetch_obj->len);
 	while (1) {
 		if (bo->fetch_obj->len > l || bo->state >= BOS_FINISHED) {
 			l = bo->fetch_obj->len;



More information about the varnish-commit mailing list