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

Unified Diff: third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.cc

Issue 1545333002: Convert Pass()→std::move() in //third_party/mojo (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
Index: third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.cc
diff --git a/third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.cc b/third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.cc
index c7bbc9514e8e5af7f65d1d262721fae41da64d69..6dc9f828e51d7be6620ef6427f3cf8939944158d 100644
--- a/third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.cc
+++ b/third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.cc
@@ -11,8 +11,8 @@
#include "third_party/mojo/src/mojo/edk/system/local_data_pipe_impl.h"
#include <string.h>
-
#include <algorithm>
+#include <utility>
#include "base/logging.h"
#include "base/memory/scoped_ptr.h"
@@ -186,7 +186,7 @@ bool LocalDataPipeImpl::ProducerEndSerialize(
// Note: Keep |*this| alive until the end of this method, to make things
// slightly easier on ourselves.
scoped_ptr<DataPipeImpl> self(owner()->ReplaceImplNoLock(make_scoped_ptr(
- new RemoteProducerDataPipeImpl(channel_endpoint.get(), buffer_.Pass(),
+ new RemoteProducerDataPipeImpl(channel_endpoint.get(), std::move(buffer_),
start_index_, current_num_bytes_))));
*actual_size = sizeof(SerializedDataPipeProducerDispatcher) +
@@ -364,7 +364,7 @@ bool LocalDataPipeImpl::ConsumerEndSerialize(
// slightly easier on ourselves.
scoped_ptr<DataPipeImpl> self(owner()->ReplaceImplNoLock(make_scoped_ptr(
new RemoteConsumerDataPipeImpl(channel_endpoint.get(), old_num_bytes,
- buffer_.Pass(), start_index_))));
+ std::move(buffer_), start_index_))));
*actual_size = sizeof(SerializedDataPipeConsumerDispatcher) +
channel->GetSerializedEndpointSize();

Powered by Google App Engine
This is Rietveld 408576698