Backed out changeset e73523d185a7 (bug 567365) for m-oth failures in test_bug112564.xul

This commit is contained in:
Carsten "Tomcat" Book 2016-01-26 16:11:13 +01:00
parent 08ba461ad4
commit fd528653dc
2 changed files with 11 additions and 5 deletions

View File

@ -12541,9 +12541,13 @@ nsDocShell::ShouldDiscardLayoutState(nsIHttpChannel* aChannel)
} }
// figure out if SH should be saving layout state // figure out if SH should be saving layout state
bool noStore = false; nsCOMPtr<nsISupports> securityInfo;
bool noStore = false, noCache = false;
aChannel->GetSecurityInfo(getter_AddRefs(securityInfo));
aChannel->IsNoStoreResponse(&noStore); aChannel->IsNoStoreResponse(&noStore);
return noStore; aChannel->IsNoCacheResponse(&noCache);
return (noStore || (noCache && securityInfo));
} }
NS_IMETHODIMP NS_IMETHODIMP

View File

@ -3206,9 +3206,11 @@ nsHttpChannel::OnCacheEntryCheck(nsICacheEntry* entry, nsIApplicationCache* appC
// which we must validate the cached response with the server. // which we must validate the cached response with the server.
else if (mLoadFlags & nsIRequest::VALIDATE_NEVER) { else if (mLoadFlags & nsIRequest::VALIDATE_NEVER) {
LOG(("VALIDATE_NEVER set\n")); LOG(("VALIDATE_NEVER set\n"));
// if no-store validate cached response (see bug 112564) // if no-store or if no-cache and ssl, validate cached response (see
if (mCachedResponseHead->NoStore()) { // bug 112564 for an explanation of this logic)
LOG(("Validating based on no-store logic\n")); if (mCachedResponseHead->NoStore() ||
(mCachedResponseHead->NoCache() && isHttps)) {
LOG(("Validating based on (no-store || (no-cache && ssl)) logic\n"));
doValidation = true; doValidation = true;
} }
else { else {