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

Unified Diff: content/browser/web_contents/web_contents_impl.cc

Issue 11801011: Also filter the URLs from incoming non-provisional navigation IPCs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/web_contents/web_contents_impl.cc
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index 8fcb09c12c4947362c05f6e3f50025238096d4af..5efad8a709d262f31e698428b6a52a04f4394d6a 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -2135,8 +2135,11 @@ void WebContentsImpl::OnDocumentLoadedInFrame(int64 frame_id) {
void WebContentsImpl::OnDidFinishLoad(
int64 frame_id,
- const GURL& validated_url,
Charlie Reis 2013/01/07 18:49:03 Wow, why was that called validated? It's coming s
+ const GURL& url,
bool is_main_frame) {
+ GURL validated_url(url);
+ RenderProcessHost* render_process_host = message_source_->GetProcess();
+ RenderViewHost::FilterURL(render_process_host, false, &validated_url);
FOR_EACH_OBSERVER(WebContentsObserver, observers_,
DidFinishLoad(frame_id, validated_url, is_main_frame,
message_source_));
@@ -2144,10 +2147,13 @@ void WebContentsImpl::OnDidFinishLoad(
void WebContentsImpl::OnDidFailLoadWithError(
int64 frame_id,
- const GURL& validated_url,
+ const GURL& url,
bool is_main_frame,
int error_code,
const string16& error_description) {
+ GURL validated_url(url);
+ RenderProcessHost* render_process_host = message_source_->GetProcess();
+ RenderViewHost::FilterURL(render_process_host, false, &validated_url);
FOR_EACH_OBSERVER(WebContentsObserver, observers_,
DidFailLoad(frame_id, validated_url, is_main_frame,
error_code, error_description,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698