Index: chrome/app/chrome_main_delegate.cc |
diff --git a/chrome/app/chrome_main_delegate.cc b/chrome/app/chrome_main_delegate.cc |
index 2ab55a5a15c796ff4473d8c6ebbb28586d36e60b..100014d394a8c2c3b9acda83c86de0d18a958c05 100644 |
--- a/chrome/app/chrome_main_delegate.cc |
+++ b/chrome/app/chrome_main_delegate.cc |
@@ -27,6 +27,7 @@ |
#include "chrome/common/chrome_paths_internal.h" |
#include "chrome/common/chrome_switches.h" |
#include "chrome/common/chrome_version_info.h" |
+#include "chrome/common/crash_keys.h" |
#include "chrome/common/logging_chrome.h" |
#include "chrome/common/profiling.h" |
#include "chrome/common/url_constants.h" |
@@ -744,6 +745,10 @@ void ChromeMainDelegate::PreSandboxStartup() { |
#endif |
} |
#endif |
+ |
+ // After all the platform Breakpads have been initialized, store the command |
+ // line for crash reporting. |
+ crash_keys::SetSwitchesFromCommandLine(&command_line); |
} |
void ChromeMainDelegate::SandboxInitialized(const std::string& process_type) { |
@@ -841,6 +846,9 @@ void ChromeMainDelegate::ZygoteForked() { |
// Needs to be called after we have chrome::DIR_USER_DATA. BrowserMain sets |
// this up for the browser process in a different manner. |
InitCrashReporter(); |
+ |
+ // Reset the command line for the newly spawned process. |
+ crash_keys::SetSwitchesFromCommandLine(CommandLine::ForCurrentProcess()); |
#endif |
} |