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

Unified Diff: content/browser/frame_host/navigator_impl.cc

Issue 1715993002: OOPIF: Fix remote frame navigations from extension pages. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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: content/browser/frame_host/navigator_impl.cc
diff --git a/content/browser/frame_host/navigator_impl.cc b/content/browser/frame_host/navigator_impl.cc
index 960ef9150e66aee0847045a0bcaaf7df3e28bf35..fd72ac112b374110ee702103832f156c53776ba9 100644
--- a/content/browser/frame_host/navigator_impl.cc
+++ b/content/browser/frame_host/navigator_impl.cc
@@ -593,7 +593,6 @@ void NavigatorImpl::RequestOpenURL(RenderFrameHostImpl* render_frame_host,
// If this came from a swapped out RenderFrameHost, we only allow the request
// if we are still in the same BrowsingInstance.
- // TODO(creis): Move this to RenderFrameProxyHost::OpenURL.
alexmos 2016/02/20 02:42:47 I'm assuming this check will have to stay in addit
Charlie Reis 2016/02/21 05:47:23 Sure, we can remove it when Nasko removes the rest
SiteInstance* current_site_instance = render_frame_host->frame_tree_node()
->current_frame_host()
->GetSiteInstance();
@@ -659,6 +658,7 @@ void NavigatorImpl::RequestOpenURL(RenderFrameHostImpl* render_frame_host,
void NavigatorImpl::RequestTransferURL(
RenderFrameHostImpl* render_frame_host,
const GURL& url,
+ SiteInstance* source_site_instance,
const std::vector<GURL>& redirect_chain,
const Referrer& referrer,
ui::PageTransition page_transition,
@@ -703,9 +703,8 @@ void NavigatorImpl::RequestTransferURL(
}
NavigationController::LoadURLParams load_url_params(dest_url);
- // The source_site_instance only matters for navigations via RenderFrameProxy,
- // which go through RequestOpenURL.
- load_url_params.source_site_instance = nullptr;
+ // The source_site_instance may matter for navigations via RenderFrameProxy.
+ load_url_params.source_site_instance = source_site_instance;
load_url_params.transition_type = page_transition;
load_url_params.frame_tree_node_id = node->frame_tree_node_id();
load_url_params.referrer = referrer_to_use;

Powered by Google App Engine
This is Rietveld 408576698