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

Unified Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 2494633004: Remove about:srcdoc url conversion. (Closed)
Patch Set: Addressed comments (@nasko). Created 4 years, 1 month 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/renderer_host/render_process_host_impl.cc
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
index c8cbea2370ade26c37a59d63bc45b09ecf01a971..cb6402307b2030656c96568e606001106ad7f1d1 100644
--- a/content/browser/renderer_host/render_process_host_impl.cc
+++ b/content/browser/renderer_host/render_process_host_impl.cc
@@ -2357,7 +2357,10 @@ void RenderProcessHostImpl::FilterURL(RenderProcessHost* rph,
if (url->SchemeIs(url::kAboutScheme)) {
// The renderer treats all URLs in the about: scheme as being about:blank.
// Canonicalize about: URLs to about:blank.
- *url = GURL(url::kAboutBlankURL);
+ // An exception is made for about:srcdoc.
+ if (*url != kAboutSrcDocURL)
+ *url = GURL(url::kAboutBlankURL);
+ return;
Charlie Reis 2016/11/16 18:20:22 Was this return added for ChildPolicySecurityPolic
arthursonzogni 2016/11/17 17:04:58 Yes it was. To be honest, I initially tried what y
Charlie Reis 2016/11/22 01:01:20 Yes, I think that makes sense, assuming we don't e
}
if (!policy->CanRequestURL(rph->GetID(), *url)) {

Powered by Google App Engine
This is Rietveld 408576698