From 2cb3e6c67ad02e3bf137f74493d28f74ca772527 Mon Sep 17 00:00:00 2001 From: "willchan@chromium.org" Date: Tue, 11 Oct 2011 04:49:32 +0000 Subject: Assert that new renderer processes aren't created during shutdown. Puts CHECKs in RenderProcessHost's constructor to make sure the main MessageLoop hasn't stopped running yet. BUG=91398 TEST=none Review URL: http://codereview.chromium.org/8210004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@104849 0039d316-1c4b-4281-b951-d872f2087c98 --- content/browser/renderer_host/render_process_host.cc | 2 ++ 1 file changed, 2 insertions(+) (limited to 'content/browser/renderer_host/render_process_host.cc') diff --git a/content/browser/renderer_host/render_process_host.cc b/content/browser/renderer_host/render_process_host.cc index 8ab4e9b..abb1680 100644 --- a/content/browser/renderer_host/render_process_host.cc +++ b/content/browser/renderer_host/render_process_host.cc @@ -7,6 +7,7 @@ #include "base/command_line.h" #include "base/rand_util.h" #include "base/sys_info.h" +#include "content/browser/browser_main.h" #include "content/browser/browser_thread.h" #include "content/browser/child_process_security_policy.h" #include "content/browser/content_browser_client.h" @@ -100,6 +101,7 @@ RenderProcessHost::RenderProcessHost(content::BrowserContext* browser_context) browser_context_(browser_context), sudden_termination_allowed_(true), ignore_input_events_(false) { + CHECK(!content::ExitedMainMessageLoop()); all_hosts.AddWithID(this, id()); all_hosts.set_check_on_null_data(true); // Initialize |child_process_activity_time_| to a reasonable value. -- cgit v1.1