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

Unified Diff: content/common_child/npobject_proxy.cc

Issue 16294003: Update content/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 7 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 | « content/common_child/npobject_proxy.h ('k') | content/common_child/npobject_stub.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common_child/npobject_proxy.cc
diff --git a/content/common_child/npobject_proxy.cc b/content/common_child/npobject_proxy.cc
index 7065607684ac3dbd3e89c93226ad752264dc5e83..13c5648bcb27e7ccf0cc266110b828f752056493 100644
--- a/content/common_child/npobject_proxy.cc
+++ b/content/common_child/npobject_proxy.cc
@@ -70,7 +70,7 @@ NPObjectProxy::NPObjectProxy(
}
NPObjectProxy::~NPObjectProxy() {
- if (channel_) {
+ if (channel_.get()) {
// This NPObjectProxy instance is now invalid and should not be reused for
// requests initiated by plugins. We may receive requests for the
// same NPObject in the context of the outgoing NPObjectMsg_Release call.
@@ -94,7 +94,7 @@ NPObject* NPObjectProxy::Create(NPChannelBase* channel,
}
bool NPObjectProxy::Send(IPC::Message* msg) {
- if (channel_)
+ if (channel_.get())
return channel_->Send(msg);
delete msg;
@@ -193,9 +193,12 @@ bool NPObjectProxy::NPInvokePrivate(NPP npp,
std::vector<NPVariant_Param> args_param;
for (unsigned int i = 0; i < arg_count; ++i) {
NPVariant_Param param;
- CreateNPVariantParam(
- args[i], channel_copy, &param, false, render_view_id,
- proxy->page_url_);
+ CreateNPVariantParam(args[i],
+ channel_copy.get(),
+ &param,
+ false,
+ render_view_id,
+ proxy->page_url_);
args_param.push_back(param);
}
@@ -224,7 +227,7 @@ bool NPObjectProxy::NPInvokePrivate(NPP npp,
return false;
CreateNPVariant(
- param_result, channel_copy, np_result, render_view_id, page_url);
+ param_result, channel_copy.get(), np_result, render_view_id, page_url);
return true;
}
@@ -419,9 +422,12 @@ bool NPObjectProxy::NPNConstruct(NPObject *obj,
std::vector<NPVariant_Param> args_param;
for (unsigned int i = 0; i < arg_count; ++i) {
NPVariant_Param param;
- CreateNPVariantParam(
- args[i], channel_copy, &param, false, render_view_id,
- proxy->page_url_);
+ CreateNPVariantParam(args[i],
+ channel_copy.get(),
+ &param,
+ false,
+ render_view_id,
+ proxy->page_url_);
args_param.push_back(param);
}
@@ -445,7 +451,7 @@ bool NPObjectProxy::NPNConstruct(NPObject *obj,
return false;
CreateNPVariant(
- param_result, channel_copy, np_result, render_view_id, page_url);
+ param_result, channel_copy.get(), np_result, render_view_id, page_url);
return true;
}
« no previous file with comments | « content/common_child/npobject_proxy.h ('k') | content/common_child/npobject_stub.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698