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

Unified Diff: content/common_child/np_channel_base.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/resource_messages.cc ('k') | content/common_child/npobject_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common_child/np_channel_base.cc
diff --git a/content/common_child/np_channel_base.cc b/content/common_child/np_channel_base.cc
index 328241c4e7b471964ef0a8e91a10bfba56498a2c..94fb6916dcf2c2b3cf70ff44b25f993363b22540 100644
--- a/content/common_child/np_channel_base.cc
+++ b/content/common_child/np_channel_base.cc
@@ -39,7 +39,7 @@ NPChannelBase* NPChannelBase::GetChannel(
channel = iter->second;
}
- DCHECK(channel != NULL);
+ DCHECK(channel.get() != NULL);
if (!channel->channel_valid()) {
channel->channel_handle_ = channel_handle;
@@ -55,7 +55,7 @@ NPChannelBase* NPChannelBase::GetChannel(
}
}
- return channel;
+ return channel.get();
}
void NPChannelBase::Broadcast(IPC::Message* message) {
@@ -81,7 +81,7 @@ NPChannelBase::~NPChannelBase() {
}
NPChannelBase* NPChannelBase::GetCurrentChannel() {
- return g_lazy_channel_stack.Pointer()->top();
+ return g_lazy_channel_stack.Pointer()->top().get();
}
void NPChannelBase::CleanupChannels() {
@@ -237,7 +237,7 @@ void NPChannelBase::RemoveRoute(int route_id) {
for (ChannelMap::iterator iter = g_channels.Get().begin();
iter != g_channels.Get().end(); ++iter) {
- if (iter->second == this) {
+ if (iter->second.get() == this) {
g_channels.Get().erase(iter);
return;
}
@@ -262,7 +262,7 @@ void NPChannelBase::OnChannelError() {
// RemoveRoute() can clean things up correctly.
for (ChannelMap::iterator iter = g_channels.Get().begin();
iter != g_channels.Get().end(); ++iter) {
- if (iter->second == this) {
+ if (iter->second.get() == this) {
// Insert new element before invalidating |iter|.
g_channels.Get()[iter->first + "-error"] = iter->second;
g_channels.Get().erase(iter);
« no previous file with comments | « content/common/resource_messages.cc ('k') | content/common_child/npobject_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698