summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/app/breakpad_linux.cc6
-rw-r--r--chrome/app/chrome_dll_main.cc7
-rw-r--r--chrome/browser/browser_main.cc5
-rw-r--r--chrome/renderer/renderer_main.cc9
4 files changed, 18 insertions, 9 deletions
diff --git a/chrome/app/breakpad_linux.cc b/chrome/app/breakpad_linux.cc
index 2b293be..588118a 100644
--- a/chrome/app/breakpad_linux.cc
+++ b/chrome/app/breakpad_linux.cc
@@ -518,8 +518,10 @@ void InitCrashReporter() {
const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess();
const std::wstring process_type =
parsed_command_line.GetSwitchValue(switches::kProcessType);
- if (process_type.empty())
+ if (process_type.empty()) {
EnableCrashDumping();
- else if (process_type == switches::kRendererProcess)
+ } else if (process_type == switches::kRendererProcess ||
+ process_type == switches::kZygoteProcess) {
EnableRendererCrashDumping();
+ }
}
diff --git a/chrome/app/chrome_dll_main.cc b/chrome/app/chrome_dll_main.cc
index 0703fc3..de4d822 100644
--- a/chrome/app/chrome_dll_main.cc
+++ b/chrome/app/chrome_dll_main.cc
@@ -50,8 +50,6 @@
#endif
#if defined(OS_MACOSX)
#include "chrome/app/breakpad_mac.h"
-#elif defined(OS_LINUX)
-#include "chrome/app/breakpad_linux.h"
#endif
#include "chrome/app/scoped_ole_initializer.h"
#include "chrome/browser/renderer_host/render_process_host.h"
@@ -420,11 +418,6 @@ int ChromeMain(int argc, const char** argv) {
if (!user_data_dir.empty())
CHECK(PathService::Override(chrome::DIR_USER_DATA, user_data_dir));
-#if defined(OS_LINUX)
- // Needs to be called after we have chrome::DIR_USER_DATA.
- InitCrashReporter();
-#endif
-
bool single_process =
#if defined (GOOGLE_CHROME_BUILD)
// This is an unsupported and not fully tested mode, so don't enable it for
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc
index 675e363..38842da 100644
--- a/chrome/browser/browser_main.cc
+++ b/chrome/browser/browser_main.cc
@@ -248,6 +248,11 @@ int BrowserMain(const MainFunctionParams& parameters) {
const CommandLine& parsed_command_line = parameters.command_line_;
base::ScopedNSAutoreleasePool* pool = parameters.autorelease_pool_;
+#if defined(OS_LINUX)
+ // Needs to be called after we have chrome::DIR_USER_DATA.
+ InitCrashReporter();
+#endif
+
// WARNING: If we get a WM_ENDSESSION objects created on the stack here
// are NOT deleted. If you need something to run during WM_ENDSESSION add it
// to browser_shutdown::Shutdown or BrowserProcess::EndSession.
diff --git a/chrome/renderer/renderer_main.cc b/chrome/renderer/renderer_main.cc
index 03e731f..55ca339 100644
--- a/chrome/renderer/renderer_main.cc
+++ b/chrome/renderer/renderer_main.cc
@@ -25,6 +25,10 @@
#include "grit/chromium_strings.h"
#include "grit/generated_resources.h"
+#if defined(OS_LINUX)
+#include "chrome/app/breakpad_linux.h"
+#endif
+
// This function provides some ways to test crash and assertion handling
// behavior of the renderer.
static void HandleRendererErrorTestParameters(const CommandLine& command_line) {
@@ -64,6 +68,11 @@ int RendererMain(const MainFunctionParams& parameters) {
const CommandLine& parsed_command_line = parameters.command_line_;
base::ScopedNSAutoreleasePool* pool = parameters.autorelease_pool_;
+#if defined(OS_LINUX)
+ // Needs to be called after we have chrome::DIR_USER_DATA.
+ InitCrashReporter();
+#endif
+
// This function allows pausing execution using the --renderer-startup-dialog
// flag allowing us to attach a debugger.
// Do not move this function down since that would mean we can't easily debug