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

Unified Diff: chrome/app/chrome_dll_main.cc

Issue 196009: Linux: set the process title (that shows in "ps" etc.) of renderers correctly when using the zygote. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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
« no previous file with comments | « base/setproctitle_linux.c ('k') | chrome/browser/renderer_host/browser_render_process_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/app/chrome_dll_main.cc
===================================================================
--- chrome/app/chrome_dll_main.cc (revision 25770)
+++ chrome/app/chrome_dll_main.cc (working copy)
@@ -97,7 +97,7 @@
#elif defined(OS_POSIX)
extern "C" {
__attribute__((visibility("default")))
-int ChromeMain(int argc, const char** argv);
+int ChromeMain(int argc, char** argv);
}
#endif
@@ -298,7 +298,7 @@
sandbox::SandboxInterfaceInfo* sandbox_info,
TCHAR* command_line) {
#elif defined(OS_POSIX)
-int ChromeMain(int argc, const char** argv) {
+int ChromeMain(int argc, char** argv) {
#endif
#if defined(OS_MACOSX)
@@ -343,6 +343,10 @@
#else
CommandLine::Init(argc, argv);
#endif
+#if defined(OS_LINUX)
+ // Set up CommandLine::SetProcTitle() support.
+ CommandLine::SetTrueArgv(argv);
+#endif
const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess();
std::wstring process_type =
@@ -594,8 +598,8 @@
// definitely harmless, so retained as a reminder of this
// requirement for gconf.
g_type_init();
- // gtk_init() can change |argc| and |argv|, but nobody else uses them.
- gtk_init(&argc, const_cast<char***>(&argv));
+ // gtk_init() can change |argc| and |argv|.
+ gtk_init(&argc, &argv);
SetUpGLibLogHandler();
#endif
« no previous file with comments | « base/setproctitle_linux.c ('k') | chrome/browser/renderer_host/browser_render_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698