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

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

Issue 22982011: Reland "Fix form resubmissions happening silently." (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: With fix Created 7 years, 4 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
« no previous file with comments | « LayoutTests/http/tests/history/back-to-post-expected.txt ('k') | Source/core/loader/DocumentLoader.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/fetch/ResourceFetcher.cpp
diff --git a/Source/core/fetch/ResourceFetcher.cpp b/Source/core/fetch/ResourceFetcher.cpp
index 28ffda05dcb4e67baff2dca19bb98a18cf005d15..74672a65e3bbac7553692ff2eccb55363221e3c2 100644
--- a/Source/core/fetch/ResourceFetcher.cpp
+++ b/Source/core/fetch/ResourceFetcher.cpp
@@ -624,11 +624,9 @@ ResourceRequestCachePolicy ResourceFetcher::resourceRequestCachePolicy(const Res
if (type == Resource::MainResource) {
FrameLoadType frameLoadType = frame()->loader()->loadType();
bool isReload = frameLoadType == FrameLoadTypeReload || frameLoadType == FrameLoadTypeReloadFromOrigin;
- if (request.httpMethod() == "POST" && (isReload || frameLoadType == FrameLoadTypeBackForward))
- return ReturnCacheDataDontLoad;
Nate Chapin 2013/08/27 21:12:41 This deletion is the only diff from what I attempt
abarth-chromium 2013/08/27 23:39:44 We talked about this in person. I think this line
if (!m_documentLoader->overrideEncoding().isEmpty() || frameLoadType == FrameLoadTypeBackForward)
return ReturnCacheDataElseLoad;
- if (isReload || frameLoadType == FrameLoadTypeSame || request.isConditional())
+ if (isReload || frameLoadType == FrameLoadTypeSame || request.isConditional() || request.httpMethod() == "POST")
return ReloadIgnoringCacheData;
return UseProtocolCachePolicy;
}
« no previous file with comments | « LayoutTests/http/tests/history/back-to-post-expected.txt ('k') | Source/core/loader/DocumentLoader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698