summaryrefslogtreecommitdiffstats
path: root/chrome/service
diff options
context:
space:
mode:
authorscottbyer@chromium.org <scottbyer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-07 23:25:19 +0000
committerscottbyer@chromium.org <scottbyer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-07 23:25:19 +0000
commit84f3d2da5271db6b299afc310c2a479b5d244822 (patch)
treefaa72462076478ff4436167ce6a07a805ddacf17 /chrome/service
parentca4b9e323b743f6687984e1a84d49542ce2ea97c (diff)
downloadchromium_src-84f3d2da5271db6b299afc310c2a479b5d244822.zip
chromium_src-84f3d2da5271db6b299afc310c2a479b5d244822.tar.gz
chromium_src-84f3d2da5271db6b299afc310c2a479b5d244822.tar.bz2
Mac/Linux proxy fix.
On Mac/Linux we keep the socket open, so don't get an OnChannelConnected message when a new Chromium launches and connects to the service, so we weren't properly marking ourselves as having a client connected. When the service was disable and Chromium exited, it meant we weren't properly exiting immediately. This is only a partial fix for the bug. BUG=74983 TEST=Start Chromium, enable the proxy, quit Chromium, start Chromium, disable the proxy, quit Chromium. With this fix the service process immediately exits. Review URL: http://codereview.chromium.org/6635023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77206 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/service')
-rw-r--r--chrome/service/service_ipc_server.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/chrome/service/service_ipc_server.cc b/chrome/service/service_ipc_server.cc
index e746b30..267a1a6 100644
--- a/chrome/service/service_ipc_server.cc
+++ b/chrome/service/service_ipc_server.cc
@@ -93,6 +93,11 @@ bool ServiceIPCServer::Send(IPC::Message* msg) {
bool ServiceIPCServer::OnMessageReceived(const IPC::Message& msg) {
bool handled = true;
+ // When we get a message, always mark the client as connected. The
+ // ChannelProxy::Context is only letting OnChannelConnected get called once,
+ // so on the Mac and Linux, we never would set client_connected_ to true
+ // again on subsequent connections.
+ client_connected_ = true;
IPC_BEGIN_MESSAGE_MAP(ServiceIPCServer, msg)
IPC_MESSAGE_HANDLER(ServiceMsg_EnableCloudPrintProxy,
OnEnableCloudPrintProxy)