From: phk Date: Mon, 25 Jun 2007 14:10:34 +0000 (+0000) Subject: Fix a NULL pointer deref in the Vary code. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2f326d4feda96bd448879704b5d582fe1dc4c02f;p=varnish Fix a NULL pointer deref in the Vary code. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@1562 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- diff --git a/varnish-cache/bin/varnishd/cache_hash.c b/varnish-cache/bin/varnishd/cache_hash.c index 7afa9eec..0693dff0 100644 --- a/varnish-cache/bin/varnishd/cache_hash.c +++ b/varnish-cache/bin/varnishd/cache_hash.c @@ -158,7 +158,7 @@ VSLR(SLT_Debug, sp->fd, sp->hash_b, sp->hash_e); o->ttl = 0; VSL(SLT_ExpBan, 0, "%u was banned", o->xid); EXP_TTLchange(o); - } else if (VRY_Match(sp, o->vary)) + } else if (o->vary != NULL && VRY_Match(sp, o->vary)) break; o->refcnt--; }