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

Unified Diff: content/browser/service_worker/service_worker_dispatcher_host.cc

Issue 2340813003: Switch base::IDMap to use unique_ptr. (Closed)
Patch Set: unique_ptr<> versions of Add/AddWithId Created 4 years, 3 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: content/browser/service_worker/service_worker_dispatcher_host.cc
diff --git a/content/browser/service_worker/service_worker_dispatcher_host.cc b/content/browser/service_worker/service_worker_dispatcher_host.cc
index 81e8a6ddd609b1a9a63039292f43e931d3cf9bb9..e8ad65462fd5a55fec7e2f098efd3c7cbf4e7aca 100644
--- a/content/browser/service_worker/service_worker_dispatcher_host.cc
+++ b/content/browser/service_worker/service_worker_dispatcher_host.cc
@@ -232,13 +232,13 @@ bool ServiceWorkerDispatcherHost::Send(IPC::Message* message) {
void ServiceWorkerDispatcherHost::RegisterServiceWorkerHandle(
std::unique_ptr<ServiceWorkerHandle> handle) {
int handle_id = handle->handle_id();
- handles_.AddWithID(handle.release(), handle_id);
+ handles_.AddWithID(std::move(handle), handle_id);
}
void ServiceWorkerDispatcherHost::RegisterServiceWorkerRegistrationHandle(
std::unique_ptr<ServiceWorkerRegistrationHandle> handle) {
int handle_id = handle->handle_id();
- registration_handles_.AddWithID(handle.release(), handle_id);
+ registration_handles_.AddWithID(std::move(handle), handle_id);
}
ServiceWorkerHandle* ServiceWorkerDispatcherHost::FindServiceWorkerHandle(

Powered by Google App Engine
This is Rietveld 408576698