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

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

Issue 2760733002: Check for already existing entry when adding to SiteProcessMap. (Closed)
Patch Set: Restore ordering of test cases in webRequestBlocking. Created 3 years, 9 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 95de1ccbbea9c12bd299148a1845846e7a4c4ce8..874668148a3fd0f258a52b7b29ff5501c169f1e5 100644
--- a/content/browser/frame_host/navigator_impl.cc
+++ b/content/browser/frame_host/navigator_impl.cc
@@ -619,12 +619,12 @@ void NavigatorImpl::DidNavigate(
}
// Update the site of the SiteInstance if it doesn't have one yet, unless
- // assigning a site is not necessary for this URL. In that case, the
- // SiteInstance can still be considered unused until a navigation to a real
- // page.
+ // assigning a site is not necessary for this URL or the commit was for an
+ // error page. In that case, the SiteInstance can still be considered unused
+ // until a navigation to a real page.
SiteInstanceImpl* site_instance = render_frame_host->GetSiteInstance();
- if (!site_instance->HasSite() &&
- ShouldAssignSiteForURL(params.url)) {
+ if (!site_instance->HasSite() && ShouldAssignSiteForURL(params.url) &&
+ !params.url_is_unreachable) {
site_instance->SetSite(params.url);
}

Powered by Google App Engine
This is Rietveld 408576698