Index: content/browser/frame_host/debug_urls.cc |
diff --git a/content/browser/frame_host/debug_urls.cc b/content/browser/frame_host/debug_urls.cc |
index 4e9d49d32a3d7be43ab7cb5b882f1cfd17c3d0d7..f61ca2822c71991b1b15046b8cd16b9dd8c0fe7b 100644 |
--- a/content/browser/frame_host/debug_urls.cc |
+++ b/content/browser/frame_host/debug_urls.cc |
@@ -43,6 +43,9 @@ bool HandleDebugURL(const GURL& url, PageTransition transition) { |
if (!(transition & PAGE_TRANSITION_FROM_ADDRESS_BAR)) |
return false; |
+ // NOTE: when you add handling of any URLs to this function, also |
+ // update IsDebugURL, below. |
+ |
if (url.host() == kChromeUIBrowserCrashHost) { |
// Induce an intentional crash in the browser process. |
CHECK(false); |
@@ -80,6 +83,19 @@ bool HandleDebugURL(const GURL& url, PageTransition transition) { |
return false; |
} |
+bool IsDebugURL(const GURL& url) { |
+ // NOTE: when you add any URLs to this list, also update |
+ // HandleDebugURL, above. |
+ return IsRendererDebugURL(url) || |
+ (url.is_valid() && |
+ (url.host() == kChromeUIBrowserCrashHost || |
+ url == GURL(kChromeUIGpuCleanURL) || |
+ url == GURL(kChromeUIGpuCrashURL) || |
+ url == GURL(kChromeUIGpuHangURL) || |
+ url == GURL(kChromeUIPpapiFlashCrashURL) || |
+ url == GURL(kChromeUIPpapiFlashHangURL))); |
+} |
+ |
bool IsRendererDebugURL(const GURL& url) { |
if (!url.is_valid()) |
return false; |