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

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

Issue 1009583004: Add UMA histograms and logging for bad IPC message handling (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: actions.xml claims to be pretty printed Created 5 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/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 0b0f411a1a041f52893e84357af935f7fe81c0df..8473c8fa776a90c5aa11f15c968a9cef629f7f27 100644
--- a/content/browser/frame_host/navigation_controller_impl.cc
+++ b/content/browser/frame_host/navigation_controller_impl.cc
@@ -14,6 +14,7 @@
#include "base/time/time.h"
#include "base/trace_event/trace_event.h"
#include "cc/base/switches.h"
+#include "content/browser/bad_message.h"
#include "content/browser/browser_url_handler_impl.h"
#include "content/browser/dom_storage/dom_storage_context_wrapper.h"
#include "content/browser/dom_storage/session_storage_namespace_impl.h"
@@ -133,8 +134,10 @@ bool AreURLsInPageNavigation(const GURL& existing_url,
!prefs.web_security_enabled ||
(prefs.allow_universal_access_from_file_urls &&
existing_url.SchemeIs(url::kFileScheme));
- if (!is_same_origin && renderer_says_in_page)
- rfh->GetProcess()->ReceivedBadMessage();
+ if (!is_same_origin && renderer_says_in_page) {
+ bad_message::ReceivedBadMessage(rfh->GetProcess(),
+ bad_message::NC_IN_PAGE_NAVIGATION);
+ }
return is_same_origin && renderer_says_in_page;
}
« no previous file with comments | « content/browser/browser_child_process_host_impl.cc ('k') | content/browser/frame_host/render_frame_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698