Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(350)

Unified Diff: third_party/WebKit/Source/core/fetch/ResourceLoader.cpp

Issue 2390583002: [WIP] WebFonts cache-aware timeout adaption (Closed)
Patch Set: check ERR_CACHE_MISS directly in ResourceError Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/fetch/ResourceLoader.cpp
diff --git a/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp b/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp
index 61b47c7850574d477ef9884ff14fd704ad6d9155..fcb16d5883d4f8cf81f14f1796871cae8beb6ccd 100644
--- a/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp
+++ b/third_party/WebKit/Source/core/fetch/ResourceLoader.cpp
@@ -137,6 +137,12 @@ bool ResourceLoader::willFollowRedirect(
DCHECK(!passedNewRequest.isNull());
DCHECK(!passedRedirectResponse.isNull());
+ if (m_resource->resourceRequest().isCacheAwareLoadingActivated()) {
+ // Fail as disk cache miss and retry in ResourceFetcher::didFailLoading().
+ didFail(nullptr, ResourceError::cacheMissError());
+ return false;
+ }
+
ResourceRequest& newRequest(passedNewRequest.toMutableResourceRequest());
const ResourceResponse& redirectResponse(
passedRedirectResponse.toResourceResponse());

Powered by Google App Engine
This is Rietveld 408576698