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

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

Issue 151593004: Fix bugs with renderer-side debug URLs, like chrome://crash or javascript:. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Clarify comments. Created 6 years, 11 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 | « content/browser/frame_host/debug_urls.cc ('k') | content/browser/frame_host/render_frame_host_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/frame_host/navigation_controller_impl.cc
diff --git a/content/browser/frame_host/navigation_controller_impl.cc b/content/browser/frame_host/navigation_controller_impl.cc
index c2ae94777cdedb8eb061d75db673433c13e0f328..b4f4cf17c9e0c0811bae0c07e5f950d11b16030c 100644
--- a/content/browser/frame_host/navigation_controller_impl.cc
+++ b/content/browser/frame_host/navigation_controller_impl.cc
@@ -642,6 +642,14 @@ void NavigationControllerImpl::LoadURLWithParams(const LoadURLParams& params) {
if (HandleDebugURL(params.url, params.transition_type))
return;
+ // Any renderer-side debug URLs or javascript: URLs should be ignored if the
+ // renderer process is not live.
+ if (IsRendererDebugURL(params.url)) {
+ // TODO(creis): Find the RVH for the correct frame.
+ if (!delegate_->GetRenderViewHost()->IsRenderViewLive())
+ return;
+ }
+
// Checks based on params.load_type.
switch (params.load_type) {
case LOAD_TYPE_DEFAULT:
« no previous file with comments | « content/browser/frame_host/debug_urls.cc ('k') | content/browser/frame_host/render_frame_host_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698