From: Garri Djavadyan Date: Thu, 15 Dec 2016 09:36:34 +0000 (+1300) Subject: Bug 3940 (partial): hostHeaderVerify failures MISS when they should be HIT X-Git-Tag: SQUID_3_5_23~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0656b73a39d30c3f96f63a3d511a57ba639ac49a;p=thirdparty%2Fsquid.git Bug 3940 (partial): hostHeaderVerify failures MISS when they should be HIT This fixes the critical condition leading to the HIT. However not all code is correctly setting flags.noCache and flags.cacheable (see bugzilla). So there may be other fixes needed after this. --- diff --git a/src/client_side_reply.cc b/src/client_side_reply.cc index 257638079a..7a9b8f8fd3 100644 --- a/src/client_side_reply.cc +++ b/src/client_side_reply.cc @@ -1649,7 +1649,9 @@ clientReplyContext::identifyStoreObject() { HttpRequest *r = http->request; - if (r->flags.cachable || r->flags.internal) { + // client sent CC:no-cache or some other condition has been + // encountered which prevents delivering a public/cached object. + if (!r->flags.noCache || r->flags.internal) { lookingforstore = 5; StoreEntry::getPublicByRequest (this, r); } else {