Commit 8f788034 authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Sanitycheck that the length of an object adds up, right when we

fetch it.


git-svn-id: http://www.varnish-cache.org/svn/trunk/varnish-cache@623 d4fa192b-c00b-0410-8231-f00ffab90ce4
parent fd02b7ef
......@@ -242,6 +242,17 @@ FetchBody(struct sess *sp)
} else
cls = 0;
{
/* Sanity check fetch methods accounting */
struct storage *st;
unsigned uu;
uu = 0;
TAILQ_FOREACH(st, &sp->obj->store, list)
uu += st->len;
assert(uu == sp->obj->len);
}
http_CopyHttp(&sp->obj->http, hp);
if (http_GetHdr(vc->http, H_Connection, &b) && !strcasecmp(b, "close"))
......
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