From 6990e5d44cd75f5427d5d2391d8330ef32bd28e7 Mon Sep 17 00:00:00 2001 From: "pph34r@gmail.com" Date: Fri, 30 Sep 2011 18:10:57 +0000 Subject: Unused variables cleanup (gcc 4.6) Make BrokerDispatcher::OnMsgConnectToPlugin report result via IPC. BUG=87490 TEST=None Review URL: http://codereview.chromium.org/8091001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@103501 0039d316-1c4b-4281-b951-d872f2087c98 --- ppapi/proxy/broker_dispatcher.cc | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'ppapi/proxy/broker_dispatcher.cc') diff --git a/ppapi/proxy/broker_dispatcher.cc b/ppapi/proxy/broker_dispatcher.cc index 0b39ae4..23c1324 100644 --- a/ppapi/proxy/broker_dispatcher.cc +++ b/ppapi/proxy/broker_dispatcher.cc @@ -57,26 +57,24 @@ bool BrokerDispatcher::OnMessageReceived(const IPC::Message& msg) { // Transfers ownership of the handle to the broker module. void BrokerDispatcher::OnMsgConnectToPlugin( PP_Instance instance, - IPC::PlatformFileForTransit handle) { - int32_t result = PP_OK; + IPC::PlatformFileForTransit handle, + int32_t* result) { if (handle == IPC::InvalidPlatformFileForTransit()) { - result = PP_ERROR_FAILED; + *result = PP_ERROR_FAILED; } else { base::SyncSocket::Handle socket_handle = IPC::PlatformFileForTransitToPlatformFile(handle); if (connect_instance_) { - result = connect_instance_(instance, PlatformFileToInt(socket_handle)); + *result = connect_instance_(instance, PlatformFileToInt(socket_handle)); } else { - result = PP_ERROR_FAILED; + *result = PP_ERROR_FAILED; // Close the handle since there is no other owner. // The easiest way to clean it up is to just put it in an object // and then close them. This failure case is not performance critical. base::SyncSocket temp_socket(socket_handle); } } - - // TODO(ddorwin): Report result via IPC. } BrokerHostDispatcher::BrokerHostDispatcher( -- cgit v1.1