diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-13 05:21:17 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-13 05:21:17 +0000 |
commit | 3cb054e682096bb5596ca0403d7fed2548c83f2c (patch) | |
tree | 9b4ab6b05693db127ef8c51baf7e951551f9e1b8 /chrome/browser/service | |
parent | 394184966eb9ce9a18d019cca3d308ec7e18f78d (diff) | |
download | chromium_src-3cb054e682096bb5596ca0403d7fed2548c83f2c.zip chromium_src-3cb054e682096bb5596ca0403d7fed2548c83f2c.tar.gz chromium_src-3cb054e682096bb5596ca0403d7fed2548c83f2c.tar.bz2 |
Remove g_browser_process dependency from content. Also make all the SyncChannels in the browser process ChannelProxy instead, since no code in the browser should send synchronous IPC messages. The renderer one was done like that a long time ago to send sync IPCs for accessibility, and we learnt that that doesn't work.
BUG=76697
Review URL: http://codereview.chromium.org/7046100
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@88806 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/service')
-rw-r--r-- | chrome/browser/service/service_process_control.cc | 6 | ||||
-rw-r--r-- | chrome/browser/service/service_process_control.h | 4 |
2 files changed, 4 insertions, 6 deletions
diff --git a/chrome/browser/service/service_process_control.cc b/chrome/browser/service/service_process_control.cc index 959c005..4461af2 100644 --- a/chrome/browser/service/service_process_control.cc +++ b/chrome/browser/service/service_process_control.cc @@ -44,10 +44,9 @@ void ServiceProcessControl::ConnectInternal() { // TODO(hclam): Handle error connecting to channel. const IPC::ChannelHandle channel_id = GetServiceProcessChannel(); - channel_.reset(new IPC::SyncChannel( + channel_.reset(new IPC::ChannelProxy( channel_id, IPC::Channel::MODE_NAMED_CLIENT, this, - BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO), true, - g_browser_process->shutdown_event())); + BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO))); } void ServiceProcessControl::RunConnectDoneTasks() { @@ -198,7 +197,6 @@ bool ServiceProcessControl::OnMessageReceived(const IPC::Message& message) { void ServiceProcessControl::OnChannelConnected(int32 peer_pid) { DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); - channel_->set_sync_messages_with_no_timeout_allowed(false); // We just established a channel with the service process. Notify it if an // upgrade is available. diff --git a/chrome/browser/service/service_process_control.h b/chrome/browser/service/service_process_control.h index b849550b..c70a947 100644 --- a/chrome/browser/service/service_process_control.h +++ b/chrome/browser/service/service_process_control.h @@ -19,7 +19,7 @@ #include "base/task.h" #include "content/common/notification_observer.h" #include "content/common/notification_registrar.h" -#include "ipc/ipc_sync_channel.h" +#include "ipc/ipc_channel_proxy.h" class CommandLine; @@ -144,7 +144,7 @@ class ServiceProcessControl : public IPC::Channel::Sender, static void RunAllTasksHelper(TaskList* task_list); // IPC channel to the service process. - scoped_ptr<IPC::SyncChannel> channel_; + scoped_ptr<IPC::ChannelProxy> channel_; // Service process launcher. scoped_refptr<Launcher> launcher_; |