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

Unified Diff: chrome/browser/printing/cloud_print/privet_notifications.cc

Issue 1641563002: Remove linked_ptr usage in //base. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 11 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
Index: chrome/browser/printing/cloud_print/privet_notifications.cc
diff --git a/chrome/browser/printing/cloud_print/privet_notifications.cc b/chrome/browser/printing/cloud_print/privet_notifications.cc
index 81c8120eff320a9ff132639ab2f8266e8f59d8bd..29275adc374b24193711a2cd184ca22bb99e8ae4 100644
--- a/chrome/browser/printing/cloud_print/privet_notifications.cc
+++ b/chrome/browser/printing/cloud_print/privet_notifications.cc
@@ -101,13 +101,11 @@ void PrivetNotificationsListener::DeviceChanged(
return; // Already saw this device.
}
- linked_ptr<DeviceContext> device_context(new DeviceContext);
-
+ scoped_ptr<DeviceContext>& device_context = devices_seen_[name];
+ device_context.reset(new DeviceContext);
device_context->notification_may_be_active = false;
device_context->registered = !description.id.empty();
- devices_seen_.insert(make_pair(name, device_context));
-
if (!device_context->registered) {
device_context->privet_http_resolution =
privet_http_factory_->CreatePrivetHTTP(name);

Powered by Google App Engine
This is Rietveld 408576698