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

Unified Diff: components/gcm_driver/instance_id/instance_id_driver.cc

Issue 1468013002: ScopedPtrMap -> std::map from /component (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nit Created 5 years, 1 month 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
Index: components/gcm_driver/instance_id/instance_id_driver.cc
diff --git a/components/gcm_driver/instance_id/instance_id_driver.cc b/components/gcm_driver/instance_id/instance_id_driver.cc
index 140d5019efd1c92e9fb09fbf444aafea74a283cc..dce5935865e18db0b9ae81270a1cf7a8e49bd4ac 100644
--- a/components/gcm_driver/instance_id/instance_id_driver.cc
+++ b/components/gcm_driver/instance_id/instance_id_driver.cc
@@ -38,11 +38,11 @@ InstanceIDDriver::~InstanceIDDriver() {
InstanceID* InstanceIDDriver::GetInstanceID(const std::string& app_id) {
auto iter = instance_id_map_.find(app_id);
if (iter != instance_id_map_.end())
- return iter->second;
+ return iter->second.get();
scoped_ptr<InstanceID> instance_id = InstanceID::Create(app_id, gcm_driver_);
InstanceID* instance_id_ptr = instance_id.get();
- instance_id_map_.insert(app_id, instance_id.Pass());
+ instance_id_map_.insert(std::make_pair(app_id, std::move(instance_id)));
return instance_id_ptr;
}

Powered by Google App Engine
This is Rietveld 408576698