Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(461)

Unified Diff: ppapi/nacl_irt/ppapi_dispatcher.cc

Issue 869883003: Never lock the Pepper proxy lock on the IO thread (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix size_t vs int32_t Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ppapi/nacl_irt/plugin_main.cc ('k') | ppapi/ppapi_proxy.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/nacl_irt/ppapi_dispatcher.cc
diff --git a/ppapi/nacl_irt/ppapi_dispatcher.cc b/ppapi/nacl_irt/ppapi_dispatcher.cc
index 059be41853532e23ac17959b292757164dccd939..343c71c2655f9c9ab01fe6d4bca941ab42d5541b 100644
--- a/ppapi/nacl_irt/ppapi_dispatcher.cc
+++ b/ppapi/nacl_irt/ppapi_dispatcher.cc
@@ -60,13 +60,18 @@ PpapiDispatcher::PpapiDispatcher(scoped_refptr<base::MessageLoopProxy> io_loop,
IPC::ChannelHandle channel_handle(
"NaCl IPC", base::FileDescriptor(browser_ipc_fd, false));
+ proxy::PluginGlobals* globals = proxy::PluginGlobals::Get();
// Delay initializing the SyncChannel until after we add filters. This
// ensures that the filters won't miss any messages received by
// the channel.
channel_ =
IPC::SyncChannel::Create(this, GetIPCMessageLoop(), GetShutdownEvent());
- channel_->AddFilter(new proxy::PluginMessageFilter(
- NULL, proxy::PluginGlobals::Get()->resource_reply_thread_registrar()));
+ scoped_refptr<ppapi::proxy::PluginMessageFilter> plugin_filter(
+ new ppapi::proxy::PluginMessageFilter(
+ NULL, globals->resource_reply_thread_registrar()));
+ channel_->AddFilter(plugin_filter.get());
+ globals->RegisterResourceMessageFilters(plugin_filter.get());
+
channel_->AddFilter(
new tracing::ChildTraceMessageFilter(message_loop_.get()));
channel_->Init(channel_handle, IPC::Channel::MODE_SERVER, true);
« no previous file with comments | « ppapi/nacl_irt/plugin_main.cc ('k') | ppapi/ppapi_proxy.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698