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

Unified Diff: content/public/browser/browser_message_filter.cc

Issue 2640083002: Crash for bad message in BrowserFilter (Closed)
Patch Set: remove OS_ANDROID Created 3 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/public/browser/browser_message_filter.cc
diff --git a/content/public/browser/browser_message_filter.cc b/content/public/browser/browser_message_filter.cc
index a6521d305acc039a647ea326dee971f41374fdde..61484741098dac5eb39b80c789f51d55be048e66 100644
--- a/content/public/browser/browser_message_filter.cc
+++ b/content/public/browser/browser_message_filter.cc
@@ -161,6 +161,11 @@ void BrowserMessageFilter::ShutdownForBadMessage() {
if (command_line->HasSwitch(switches::kDisableKillAfterBadIPC))
return;
+ if (base::Process::Current().Handle() == peer_process_.Handle()) {
+ // Just crash in single process. Matches RenderProcessHostImpl behavior.
+ CHECK(false);
+ }
+
ChildProcessLauncher::TerminateProcess(
peer_process_, content::RESULT_CODE_KILLED_BAD_MESSAGE, false);
« 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