Chromium Code Reviews| Index: content/browser/renderer_host/pepper/browser_ppapi_host_impl.cc |
| diff --git a/content/browser/renderer_host/pepper/browser_ppapi_host_impl.cc b/content/browser/renderer_host/pepper/browser_ppapi_host_impl.cc |
| index d7f4647567d86f0f970a67b0f81433dc7bd944fd..d263ee1c91eb06ce2a315b981dfe1799e80b6072 100644 |
| --- a/content/browser/renderer_host/pepper/browser_ppapi_host_impl.cc |
| +++ b/content/browser/renderer_host/pepper/browser_ppapi_host_impl.cc |
| @@ -141,6 +141,14 @@ void BrowserPpapiHostImpl::SetOnKeepaliveCallback( |
| on_keepalive_callback_ = callback; |
| } |
| +bool BrowserPpapiHostImpl::IsPotentiallySecurePluginContext( |
| + PP_Instance instance) { |
| + auto* data = instance_map_.get(instance); |
|
Ryan Sleevi
2015/05/12 22:56:05
nit: why the auto*? Why not let auto bind to the a
dcheng
2015/05/12 23:56:20
(I'm not raymes@ but I personally prefer auto* whe
raymes
2015/05/13 00:07:19
I copied the code from other functions in here. I'
raymes
2015/05/13 00:08:00
based on dcheng's comment, I left it as-is :P but
|
| + if (data == nullptr) |
| + return false; |
| + return data->renderer_data.is_potentially_secure_plugin_context; |
| +} |
| + |
| void BrowserPpapiHostImpl::AddInstance( |
| PP_Instance instance, |
| const PepperRendererInstanceData& renderer_instance_data) { |