]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Fix other issues in rev.13143
authorAmos Jeffries <squid3@treenet.co.nz>
Sat, 23 Nov 2013 05:21:34 +0000 (22:21 -0700)
committerAmos Jeffries <squid3@treenet.co.nz>
Sat, 23 Nov 2013 05:21:34 +0000 (22:21 -0700)
src/http.cc
src/ssl/ErrorDetailManager.cc

index 496001d7bd1f2143edc9907d61ecdac8e351f8ea..99773d74f7c29cb5a7687f4735bb9abbb0770bb3 100644 (file)
@@ -427,7 +427,7 @@ HttpStateData::cacheableReply()
             // HTTPbis WG verdict on this is that it is omitted from the spec due to being 'unexpected' by
             // some. The caching+revalidate is not exactly unsafe though with Squids interpretation of no-cache
             // (without parameters) as equivalent to must-revalidate in the reply.
-        } else if (rep->cache_control->hasNoCache() && rep->cache_control->noCache().size() > 0 && !REFRESH_OVERRIDE(ignore_must_revalidate)) {
+        } else if (rep->cache_control->hasNoCache() && rep->cache_control->noCache().size() == 0 && !REFRESH_OVERRIDE(ignore_must_revalidate)) {
             debugs(22, 3, HERE << "Authenticated but server reply Cache-Control:no-cache (equivalent to must-revalidate)");
             mayStore = true;
 #endif
index e136dfa978669b6acedd1bf47b2762b4e3ce1ead..5796f9c0b16bc3a9ec0f49a4e97c96c6465f954c 100644 (file)
@@ -230,9 +230,9 @@ Ssl::ErrorDetailFile::parse(const char *buffer, int len, bool eof)
                 entry.error_no = ssl_error;
                 entry.name = errorName;
                 String tmp = parser.getByName("detail");
-                int detailsParseOk = httpHeaderParseQuotedString(tmp.termedBuf(), tmp.size(), &entry.detail);
+                const int detailsParseOk = httpHeaderParseQuotedString(tmp.termedBuf(), tmp.size(), &entry.detail);
                 tmp = parser.getByName("descr");
-                int descrParseOk = httpHeaderParseQuotedString(tmp.termedBuf(), tmp.size(), &entry.descr);
+                const int descrParseOk = httpHeaderParseQuotedString(tmp.termedBuf(), tmp.size(), &entry.descr);
 
                 if (!detailsParseOk || !descrParseOk) {
                     debugs(83, DBG_IMPORTANT, HERE <<