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

Unified Diff: remoting/host/it2me/it2me_native_messaging_host_main.cc

Issue 1549493004: Use std::move() instead of .Pass() in remoting/host (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_not_pass
Patch Set: include <utility> 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: remoting/host/it2me/it2me_native_messaging_host_main.cc
diff --git a/remoting/host/it2me/it2me_native_messaging_host_main.cc b/remoting/host/it2me/it2me_native_messaging_host_main.cc
index 0fb94c8fdace297ce0db776cc3efd91e4c3b45dc..b853ce9a5c1cf28e93717e9c513e2bb19bc724ec 100644
--- a/remoting/host/it2me/it2me_native_messaging_host_main.cc
+++ b/remoting/host/it2me/it2me_native_messaging_host_main.cc
@@ -4,6 +4,8 @@
#include "remoting/host/it2me/it2me_native_messaging_host_main.h"
+#include <utility>
+
#include "base/at_exit.h"
#include "base/command_line.h"
#include "base/i18n/icu_util.h"
@@ -122,17 +124,17 @@ int StartIt2MeNativeMessagingHost() {
// Set up the native messaging channel.
scoped_ptr<extensions::NativeMessagingChannel> channel(
- new PipeMessagingChannel(read_file.Pass(), write_file.Pass()));
+ new PipeMessagingChannel(std::move(read_file), std::move(write_file)));
scoped_ptr<ChromotingHostContext> context =
ChromotingHostContext::Create(new remoting::AutoThreadTaskRunner(
message_loop.task_runner(), run_loop.QuitClosure()));
scoped_ptr<extensions::NativeMessageHost> host(
- new It2MeNativeMessagingHost(context.Pass(), factory.Pass()));
+ new It2MeNativeMessagingHost(std::move(context), std::move(factory)));
host->Start(native_messaging_pipe.get());
- native_messaging_pipe->Start(host.Pass(), channel.Pass());
+ native_messaging_pipe->Start(std::move(host), std::move(channel));
// Run the loop until channel is alive.
run_loop.Run();
« no previous file with comments | « remoting/host/it2me/it2me_native_messaging_host.cc ('k') | remoting/host/it2me/it2me_native_messaging_host_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698