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

Unified Diff: content/renderer/render_view_impl.cc

Issue 8669014: Fix a bug where redirect chain gets lost on process swap. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: latest Created 9 years 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: content/renderer/render_view_impl.cc
diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc
index a8513016977f421f951dea955a68a2a47402d2bb..dee3c42fc2852a6e7365b5eb916e1080529f4de4 100644
--- a/content/renderer/render_view_impl.cc
+++ b/content/renderer/render_view_impl.cc
@@ -2059,7 +2059,7 @@ WebNavigationPolicy RenderViewImpl::decidePolicyForNavigation(
//
// TODO(creis): Move this redirect check to the browser process to avoid
// ping-ponging. See http://crbug.com/72380.
Charlie Reis 2011/12/02 22:38:11 Remove TODO?
Matt Perry 2011/12/03 00:14:24 Done.
- if (!frame->parent() && (is_content_initiated || is_redirect) &&
+ if (!frame->parent() && is_content_initiated &&
default_policy == WebKit::WebNavigationPolicyCurrentTab &&
request.httpMethod() == "GET" && !url.SchemeIs(chrome::kAboutScheme)) {
bool send_referrer = false;
@@ -2332,6 +2332,10 @@ void RenderViewImpl::PopulateStateFromPendingNavigationParams(
params.page_id,
params.pending_history_list_offset,
params.transition);
+ navigation_state->set_transferred_request_child_id(
+ params.transferred_request_child_id);
+ navigation_state->set_transferred_request_request_id(
+ params.transferred_request_request_id);
if (params.navigation_type == ViewMsg_Navigate_Type::RESTORE) {
// We're doing a load of a page that was restored from the last session.
// By default this prefers the cache over loading (LOAD_PREFERRING_CACHE)
@@ -2732,7 +2736,9 @@ void RenderViewImpl::willSendRequest(WebFrame* frame,
frame->identifier(),
frame->parent() == top_frame,
frame->parent() ? frame->parent()->identifier() : -1,
- transition_type));
+ transition_type,
+ navigation_state->transferred_request_child_id(),
+ navigation_state->transferred_request_request_id()));
DocumentState* top_document_state =
DocumentState::FromDataSource(top_data_source);

Powered by Google App Engine
This is Rietveld 408576698