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

Unified Diff: net/ssl/default_channel_id_store.cc

Issue 1545233002: Convert Pass()→std::move() in //net (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 | « net/ssl/client_cert_store_nss.cc ('k') | net/ssl/default_channel_id_store_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/ssl/default_channel_id_store.cc
diff --git a/net/ssl/default_channel_id_store.cc b/net/ssl/default_channel_id_store.cc
index f9db093f132225d82fb7c0f20a64e558e940043e..8fff6f0413246bd9e5bbeed5c9ec8d85a45373c3 100644
--- a/net/ssl/default_channel_id_store.cc
+++ b/net/ssl/default_channel_id_store.cc
@@ -4,6 +4,8 @@
#include "net/ssl/default_channel_id_store.h"
+#include <utility>
+
#include "base/bind.h"
#include "base/message_loop/message_loop.h"
#include "base/metrics/histogram_macros.h"
@@ -68,7 +70,7 @@ void DefaultChannelIDStore::GetChannelIDTask::Run(
DCHECK(err != ERR_IO_PENDING);
InvokeCallback(base::Bind(callback_, err, server_identifier_,
- base::Passed(key_result.Pass())));
+ base::Passed(std::move(key_result))));
}
// --------------------------------------------------------------------------
@@ -86,15 +88,14 @@ class DefaultChannelIDStore::SetChannelIDTask
DefaultChannelIDStore::SetChannelIDTask::SetChannelIDTask(
scoped_ptr<ChannelID> channel_id)
- : channel_id_(channel_id.Pass()) {
-}
+ : channel_id_(std::move(channel_id)) {}
DefaultChannelIDStore::SetChannelIDTask::~SetChannelIDTask() {
}
void DefaultChannelIDStore::SetChannelIDTask::Run(
DefaultChannelIDStore* store) {
- store->SyncSetChannelID(channel_id_.Pass());
+ store->SyncSetChannelID(std::move(channel_id_));
}
// --------------------------------------------------------------------------
@@ -235,7 +236,7 @@ int DefaultChannelIDStore::GetChannelID(
}
void DefaultChannelIDStore::SetChannelID(scoped_ptr<ChannelID> channel_id) {
- auto task = new SetChannelIDTask(channel_id.Pass());
+ auto task = new SetChannelIDTask(std::move(channel_id));
RunOrEnqueueTask(scoped_ptr<Task>(task));
}
@@ -337,7 +338,7 @@ void DefaultChannelIDStore::SyncSetChannelID(scoped_ptr<ChannelID> channel_id) {
DCHECK(loaded_);
InternalDeleteChannelID(channel_id->server_identifier());
- InternalInsertChannelID(channel_id.Pass());
+ InternalInsertChannelID(std::move(channel_id));
}
void DefaultChannelIDStore::SyncDeleteChannelID(
@@ -382,7 +383,7 @@ void DefaultChannelIDStore::EnqueueTask(scoped_ptr<Task> task) {
DCHECK(!loaded_);
if (waiting_tasks_.empty())
waiting_tasks_start_time_ = base::TimeTicks::Now();
- waiting_tasks_.push_back(task.Pass());
+ waiting_tasks_.push_back(std::move(task));
}
void DefaultChannelIDStore::RunOrEnqueueTask(scoped_ptr<Task> task) {
@@ -390,7 +391,7 @@ void DefaultChannelIDStore::RunOrEnqueueTask(scoped_ptr<Task> task) {
InitIfNecessary();
if (!loaded_) {
- EnqueueTask(task.Pass());
+ EnqueueTask(std::move(task));
return;
}
« no previous file with comments | « net/ssl/client_cert_store_nss.cc ('k') | net/ssl/default_channel_id_store_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698