Index: content/app/content_main_runner.cc |
diff --git a/content/app/content_main_runner.cc b/content/app/content_main_runner.cc |
index 2151a26fb62c4d296f43fa58ea64bb82265f20f8..5f5f8e5cd2e4f24fc70aadafbd9586162a6a263e 100644 |
--- a/content/app/content_main_runner.cc |
+++ b/content/app/content_main_runner.cc |
@@ -205,7 +205,10 @@ void CommonSubprocessInit(const std::string& process_type) { |
#if !defined(OFFICIAL_BUILD) |
// Print stack traces to stderr when crashes occur. This opens up security |
// holes so it should never be enabled for official builds. |
- base::debug::EnableInProcessStackDumping(); |
+ if (!base::CommandLine::ForCurrentProcess()->HasSwitch( |
+ switches::kDisableInProcessStackTraces)) { |
+ base::debug::EnableInProcessStackDumping(); |
+ } |
#if defined(OS_WIN) |
base::RouteStdioToConsole(false); |
LoadLibraryA("dbghelp.dll"); |