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

Unified Diff: content/browser/browser_child_process_host_impl.cc

Issue 11103028: Logging: pass logging related cmd line options to utility process (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: move common switches propagation related to logging to BrowserChildProcessHostImpl::Launch() Created 8 years, 2 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
Index: content/browser/browser_child_process_host_impl.cc
diff --git a/content/browser/browser_child_process_host_impl.cc b/content/browser/browser_child_process_host_impl.cc
index 6c7dd9c902389025f625c0d9a9f9d4594e379cb3..229968ee5cbecb6efe366e4db4eefbd3ab9a176e 100644
--- a/content/browser/browser_child_process_host_impl.cc
+++ b/content/browser/browser_child_process_host_impl.cc
@@ -4,6 +4,7 @@
#include "content/browser/browser_child_process_host_impl.h"
+#include "base/base_switches.h"
#include "base/bind.h"
#include "base/command_line.h"
#include "base/file_path.h"
@@ -121,6 +122,19 @@ void BrowserChildProcessHostImpl::Launch(
content::GetContentClient()->browser()->AppendExtraCommandLineSwitches(
cmd_line, data_.id);
+ const CommandLine& browser_command_line = *CommandLine::ForCurrentProcess();
+ static const char* kForwardSwitches[] = {
piman 2012/10/17 06:10:25 nit: can you add: #if defined(OS_POSIX) switch
qiankun 2012/10/17 09:47:37 Done.
+ switches::kDisableLogging,
+ switches::kEnableDCHECK,
+ switches::kEnableLogging,
+ switches::kLoggingLevel,
+ switches::kV,
+ switches::kVModule,
+ };
+ cmd_line->CopySwitchesFrom(browser_command_line, kForwardSwitches,
+ arraysize(kForwardSwitches));
+
+
#if defined(OS_POSIX)
if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kChildCleanExit))
cmd_line->AppendSwitch(switches::kChildCleanExit);

Powered by Google App Engine
This is Rietveld 408576698