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

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

Issue 2509533002: Do not add a Resource with DoNotBufferData policy to the memory cache (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp
diff --git a/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp b/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp
index 8c5fbea3b7acbaf24b5ff48310298d3fbbfb94ed..caf9089d78a91c17f1a61f225469287386721f68 100644
--- a/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp
+++ b/third_party/WebKit/Source/core/fetch/ResourceFetcher.cpp
@@ -745,7 +745,8 @@ Resource* ResourceFetcher::createResourceForLoading(
resource->setCacheIdentifier(cacheIdentifier);
// Don't add main resource to cache to prevent reuse.
hiroshige 2016/11/16 06:34:58 Please update the comment.
yhirano 2016/11/16 07:21:49 Done.
- if (factory.type() != Resource::MainResource)
+ if (factory.type() != Resource::MainResource &&
+ request.options().dataBufferingPolicy == BufferData)
hiroshige 2016/11/16 06:34:58 optional: |request.options().dataBufferingPolicy !
yhirano 2016/11/16 07:21:49 Done.
memoryCache()->add(resource);
return resource;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698