diff options
author | rsleevi@chromium.org <rsleevi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-06-02 21:13:46 +0000 |
---|---|---|
committer | rsleevi@chromium.org <rsleevi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-06-02 21:13:46 +0000 |
commit | fc72bb18b111ff63e57135d97de6d59291f3b7b8 (patch) | |
tree | f7fedf0a0577e38a0486e8bdc88a47a508bf122d /content/plugin | |
parent | 7cd76fded67d66fb8ea4f5abce5241ad71d749a9 (diff) | |
download | chromium_src-fc72bb18b111ff63e57135d97de6d59291f3b7b8.zip chromium_src-fc72bb18b111ff63e57135d97de6d59291f3b7b8.tar.gz chromium_src-fc72bb18b111ff63e57135d97de6d59291f3b7b8.tar.bz2 |
Update content/ to use scoped_refptr<T>::get() rather than implicit "operator T*"
Linux fixes
BUG=110610
TBR=darin
Review URL: https://chromiumcodereview.appspot.com/16294003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@203624 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/plugin')
-rw-r--r-- | content/plugin/plugin_channel.cc | 4 | ||||
-rw-r--r-- | content/plugin/plugin_thread.cc | 4 | ||||
-rw-r--r-- | content/plugin/webplugin_delegate_stub.cc | 6 | ||||
-rw-r--r-- | content/plugin/webplugin_proxy.cc | 14 |
4 files changed, 17 insertions, 11 deletions
diff --git a/content/plugin/plugin_channel.cc b/content/plugin/plugin_channel.cc index bc13d39..8c0321f 100644 --- a/content/plugin/plugin_channel.cc +++ b/content/plugin/plugin_channel.cc @@ -263,7 +263,7 @@ void PluginChannel::OnCreateInstance(const std::string& mime_type, *instance_id = GenerateRouteID(); scoped_refptr<WebPluginDelegateStub> stub(new WebPluginDelegateStub( mime_type, *instance_id, this)); - AddRoute(*instance_id, stub, NULL); + AddRoute(*instance_id, stub.get(), NULL); plugin_stubs_.push_back(stub); } @@ -305,7 +305,7 @@ void PluginChannel::OnClearSiteData(const std::string& site, base::FilePath path = command_line->GetSwitchValuePath(switches::kPluginPath); scoped_refptr<webkit::npapi::PluginLib> plugin_lib( webkit::npapi::PluginLib::CreatePluginLib(path)); - if (plugin_lib) { + if (plugin_lib.get()) { NPError err = plugin_lib->NP_Initialize(); if (err == NPERR_NO_ERROR) { const char* site_str = site.empty() ? NULL : site.c_str(); diff --git a/content/plugin/plugin_thread.cc b/content/plugin/plugin_thread.cc index 623bd88..0be9a91 100644 --- a/content/plugin/plugin_thread.cc +++ b/content/plugin/plugin_thread.cc @@ -118,7 +118,7 @@ PluginThread::PluginThread() scoped_refptr<webkit::npapi::PluginLib> plugin( webkit::npapi::PluginLib::CreatePluginLib(plugin_path)); - if (plugin) { + if (plugin.get()) { plugin->NP_Initialize(); // For OOP plugins the plugin dll will be unloaded during process shutdown // time. @@ -174,7 +174,7 @@ void PluginThread::OnCreateChannel(int renderer_id, scoped_refptr<PluginChannel> channel(PluginChannel::GetPluginChannel( renderer_id, ChildProcess::current()->io_message_loop_proxy())); IPC::ChannelHandle channel_handle; - if (channel) { + if (channel.get()) { channel_handle.name = channel->channel_handle().name; #if defined(OS_POSIX) // On POSIX, pass the renderer-side FD. diff --git a/content/plugin/webplugin_delegate_stub.cc b/content/plugin/webplugin_delegate_stub.cc index 3e472af..2b76d8d 100644 --- a/content/plugin/webplugin_delegate_stub.cc +++ b/content/plugin/webplugin_delegate_stub.cc @@ -165,8 +165,10 @@ void WebPluginDelegateStub::OnInit(const PluginMsg_Init_Params& params, base::FilePath path = command_line.GetSwitchValuePath(switches::kPluginPath); - webplugin_ = new WebPluginProxy( - channel_, instance_id_, page_url_, params.host_render_view_routing_id); + webplugin_ = new WebPluginProxy(channel_.get(), + instance_id_, + page_url_, + params.host_render_view_routing_id); delegate_ = webkit::npapi::WebPluginDelegateImpl::Create(path, mime_type_); if (delegate_) { webplugin_->set_delegate(delegate_); diff --git a/content/plugin/webplugin_proxy.cc b/content/plugin/webplugin_proxy.cc index f0834d0..5817060 100644 --- a/content/plugin/webplugin_proxy.cc +++ b/content/plugin/webplugin_proxy.cc @@ -220,8 +220,10 @@ NPObject* WebPluginProxy::GetWindowScriptNPObject() { if (!success) return NULL; - window_npobject_ = NPObjectProxy::Create( - channel_, npobject_route_id, host_render_view_routing_id_, page_url_); + window_npobject_ = NPObjectProxy::Create(channel_.get(), + npobject_route_id, + host_render_view_routing_id_, + page_url_); return window_npobject_; } @@ -237,8 +239,10 @@ NPObject* WebPluginProxy::GetPluginElement() { if (!success) return NULL; - plugin_element_ = NPObjectProxy::Create( - channel_, npobject_route_id, host_render_view_routing_id_, page_url_); + plugin_element_ = NPObjectProxy::Create(channel_.get(), + npobject_route_id, + host_render_view_routing_id_, + page_url_); return plugin_element_; } @@ -278,7 +282,7 @@ WebPluginResourceClient* WebPluginProxy::GetResourceClient(int id) { } int WebPluginProxy::GetRendererId() { - if (channel_) + if (channel_.get()) return channel_->renderer_id(); return -1; } |