| Index: content/browser/utility_process_host.cc
|
| ===================================================================
|
| --- content/browser/utility_process_host.cc (revision 112597)
|
| +++ content/browser/utility_process_host.cc (working copy)
|
| @@ -9,6 +9,7 @@
|
| #include "base/command_line.h"
|
| #include "base/message_loop.h"
|
| #include "base/utf_string_conversions.h"
|
| +#include "content/common/child_process_host.h"
|
| #include "content/common/utility_messages.h"
|
| #include "content/public/browser/content_browser_client.h"
|
| #include "content/public/common/content_switches.h"
|
| @@ -40,9 +41,9 @@
|
| is_batch_mode_(false),
|
| no_sandbox_(false),
|
| #if defined(OS_LINUX)
|
| - child_flags_(CHILD_ALLOW_SELF),
|
| + child_flags_(ChildProcessHost::CHILD_ALLOW_SELF),
|
| #else
|
| - child_flags_(CHILD_NORMAL),
|
| + child_flags_(ChildProcessHost::CHILD_NORMAL),
|
| #endif
|
| started_(false) {
|
| }
|
| @@ -72,7 +73,7 @@
|
| }
|
|
|
| FilePath UtilityProcessHost::GetUtilityProcessCmd() {
|
| - return GetChildPath(child_flags_);
|
| + return ChildProcessHost::GetChildPath(child_flags_);
|
| }
|
|
|
| bool UtilityProcessHost::StartProcess() {
|
| @@ -86,7 +87,7 @@
|
| // launches a UtilityProcessHost.
|
| set_name(ASCIIToUTF16("utility process"));
|
|
|
| - if (!CreateChannel())
|
| + if (!child_process_host()->CreateChannel())
|
| return false;
|
|
|
| FilePath exe_path = GetUtilityProcessCmd();
|
| @@ -98,7 +99,8 @@
|
| CommandLine* cmd_line = new CommandLine(exe_path);
|
| cmd_line->AppendSwitchASCII(switches::kProcessType,
|
| switches::kUtilityProcess);
|
| - cmd_line->AppendSwitchASCII(switches::kProcessChannelID, channel_id());
|
| + cmd_line->AppendSwitchASCII(switches::kProcessChannelID,
|
| + child_process_host()->channel_id());
|
| std::string locale =
|
| content::GetContentClient()->browser()->GetApplicationLocale();
|
| cmd_line->AppendSwitchASCII(switches::kLang, locale);
|
| @@ -151,7 +153,3 @@
|
| client_thread_id_, FROM_HERE,
|
| base::Bind(&Client::OnProcessCrashed, client_.get(), exit_code));
|
| }
|
| -
|
| -bool UtilityProcessHost::CanShutdown() {
|
| - return true;
|
| -}
|
|
|