Commit 12a4d079 authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Make sure to release the waiting list, if we give up caching before

picking up the object body.

Fixes #667



git-svn-id: http://www.varnish-cache.org/svn/trunk/varnish-cache@4631 d4fa192b-c00b-0410-8231-f00ffab90ce4
parent abe5d56b
......@@ -154,6 +154,7 @@ HSH_DeleteObjHead(struct worker *w, struct objhead *oh)
AZ(oh->refcnt);
assert(VTAILQ_EMPTY(&oh->objcs));
assert(VTAILQ_EMPTY(&oh->waitinglist));
Lck_Delete(&oh->mtx);
w->stats.n_objecthead--;
FREE_OBJ(oh);
......@@ -571,6 +572,8 @@ HSH_DerefObjCore(struct sess *sp)
Lck_Lock(&oh->mtx);
assert(oc->objhead == oh);
VTAILQ_REMOVE(&oh->objcs, oc, list);
if (oc->flags & OC_F_BUSY)
hsh_rush(oh);
Lck_Unlock(&oh->mtx);
oc->objhead = NULL;
assert(oh->refcnt > 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment