PPAPI: Make GetProxiedInterface not re-enter the plugin
commita17de8faa97ca33d1e58e08392dbdc3e316d6cbe
authordmichael <dmichael@chromium.org>
Fri, 7 Nov 2014 17:17:56 +0000 (7 09:17 -0800)
committerCommit bot <commit-bot@chromium.org>
Fri, 7 Nov 2014 17:18:14 +0000 (7 17:18 +0000)
tree46287d32709cf5bd29671e8610cc29c6dfa01c28
parentb5f9bafa5ed8971b7d78ae0a7a457129742d3890
PPAPI: Make GetProxiedInterface not re-enter the plugin

It's important that we never re-enter the plugin when it is blocked on
synchronous calls to the renderer (unless they are scripting messages, which
have to be re-entrant). This especially breaks assumptions in OpenGL usage.

This required making the plugin side of the PPB_VideoDecoder_Dev proxy check
for the interface prior to sending its synchronous Create message. I audited
all the other uses of GetProxiedInterface from the renderer, and none of the
others happen as a result of a sync plugin->renderer message.

I also renamed the existing "SupportsInterface" message to "IsInterfaceSupported" to make the intent more obvious, and because I liked the SupportsInterface name better for the new usage: Telling the renderer that an interface is supported.

BUG=418651

Review URL: https://codereview.chromium.org/704913002

Cr-Commit-Position: refs/heads/master@{#303247}
ppapi/proxy/host_dispatcher.cc
ppapi/proxy/host_dispatcher.h
ppapi/proxy/plugin_dispatcher.cc
ppapi/proxy/plugin_dispatcher.h
ppapi/proxy/plugin_dispatcher_unittest.cc
ppapi/proxy/ppapi_messages.h
ppapi/proxy/ppapi_proxy_test.cc
ppapi/proxy/ppapi_proxy_test.h
ppapi/proxy/ppb_video_decoder_proxy.cc