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

Unified Diff: mojo/public/cpp/bindings/lib/multiplex_router.cc

Issue 1535943002: Convert Pass()→std::move() in //mojo/public/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Regenerate correctly 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
Index: mojo/public/cpp/bindings/lib/multiplex_router.cc
diff --git a/mojo/public/cpp/bindings/lib/multiplex_router.cc b/mojo/public/cpp/bindings/lib/multiplex_router.cc
index 9375e60b3db37355ec9a988829526bdf8945ab92..b756202b58048b8c80b0816720dc6877f680acf6 100644
--- a/mojo/public/cpp/bindings/lib/multiplex_router.cc
+++ b/mojo/public/cpp/bindings/lib/multiplex_router.cc
@@ -124,7 +124,9 @@ MultiplexRouter::MultiplexRouter(bool set_interface_id_namesapce_bit,
->task_runner()),
set_interface_id_namespace_bit_(set_interface_id_namesapce_bit),
header_validator_(this),
- connector_(message_pipe.Pass(), Connector::MULTI_THREADED_SEND, waiter),
+ connector_(std::move(message_pipe),
+ Connector::MULTI_THREADED_SEND,
+ waiter),
encountered_error_(false),
control_message_handler_(this),
control_message_proxy_(&connector_),
@@ -293,7 +295,7 @@ void MultiplexRouter::RaiseError() {
scoped_ptr<AssociatedGroup> MultiplexRouter::CreateAssociatedGroup() {
scoped_ptr<AssociatedGroup> group(new AssociatedGroup);
group->router_ = this;
- return group.Pass();
+ return group;
}
// static
@@ -400,7 +402,7 @@ void MultiplexRouter::ProcessTasks(bool force_async) {
lock_.AssertAcquired();
while (!tasks_.empty()) {
- scoped_ptr<Task> task(tasks_.front().Pass());
+ scoped_ptr<Task> task(std::move(tasks_.front()));
tasks_.pop_front();
bool processed = task->IsNotifyErrorTask()
@@ -408,7 +410,7 @@ void MultiplexRouter::ProcessTasks(bool force_async) {
: ProcessIncomingMessageTask(task.get(), &force_async);
if (!processed) {
- tasks_.push_front(task.Pass());
+ tasks_.push_front(std::move(task));
break;
}
}
@@ -488,7 +490,7 @@ bool MultiplexRouter::ProcessIncomingMessageTask(Task* task,
*force_async = true;
InterfaceEndpointClient* client = endpoint->client();
- scoped_ptr<Message> owned_message = task->message.Pass();
+ scoped_ptr<Message> owned_message = std::move(task->message);
bool result = false;
{
// We must unlock before calling into |client| because it may call this
« no previous file with comments | « mojo/public/cpp/bindings/lib/map_serialization.h ('k') | mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698