summaryrefslogtreecommitdiffstats
path: root/webkit/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/plugins')
-rw-r--r--webkit/plugins/ppapi/ppb_broker_impl.cc8
-rw-r--r--webkit/plugins/ppapi/ppb_broker_impl.h2
2 files changed, 6 insertions, 4 deletions
diff --git a/webkit/plugins/ppapi/ppb_broker_impl.cc b/webkit/plugins/ppapi/ppb_broker_impl.cc
index 959830a..16aa316 100644
--- a/webkit/plugins/ppapi/ppb_broker_impl.cc
+++ b/webkit/plugins/ppapi/ppb_broker_impl.cc
@@ -128,8 +128,10 @@ PPB_Broker_Impl* PPB_Broker_Impl::AsPPB_Broker_Impl() {
}
// Transfers ownership of the handle to the plugin.
-void PPB_Broker_Impl::BrokerConnected(int32_t handle) {
- DCHECK(handle);
+void PPB_Broker_Impl::BrokerConnected(int32_t handle, int32_t result) {
+ DCHECK(result == PP_OK ||
+ handle == PlatformFileToInt(base::kInvalidPlatformFileValue));
+
pipe_handle_ = handle;
// Synchronous calls are not supported.
@@ -137,7 +139,7 @@ void PPB_Broker_Impl::BrokerConnected(int32_t handle) {
scoped_refptr<TrackedCompletionCallback> callback;
callback.swap(connect_callback_);
- callback->Run(PP_OK); // Will complete abortively if necessary.
+ callback->Run(result); // Will complete abortively if necessary.
}
} // namespace ppapi
diff --git a/webkit/plugins/ppapi/ppb_broker_impl.h b/webkit/plugins/ppapi/ppb_broker_impl.h
index 2e7b0b6..5bba19a 100644
--- a/webkit/plugins/ppapi/ppb_broker_impl.h
+++ b/webkit/plugins/ppapi/ppb_broker_impl.h
@@ -33,7 +33,7 @@ class PPB_Broker_Impl : public Resource {
// Resource override.
virtual PPB_Broker_Impl* AsPPB_Broker_Impl();
- virtual void BrokerConnected(int32_t handle);
+ void BrokerConnected(int32_t handle, int32_t result);
private:
// PluginDelegate ppapi broker object.