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

Unified Diff: util/mach/child_port_handshake.cc

Issue 1483073004: Replace use of .Pass() with crashpad::move(). (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: pass: . Created 5 years, 1 month 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 | « util/mach/child_port_handshake.h ('k') | util/net/http_transport.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: util/mach/child_port_handshake.cc
diff --git a/util/mach/child_port_handshake.cc b/util/mach/child_port_handshake.cc
index e7cc7eed38343716d292d4eac2f89d91ef9d00fc..3fe4c449a7b7e23d298d2141367ac100a97f1498 100644
--- a/util/mach/child_port_handshake.cc
+++ b/util/mach/child_port_handshake.cc
@@ -37,6 +37,7 @@
#include "util/mach/mach_message.h"
#include "util/mach/mach_message_server.h"
#include "util/misc/implicit_cast.h"
+#include "util/stdlib/move.h"
#include "util/misc/random_string.h"
namespace crashpad {
@@ -352,30 +353,30 @@ ChildPortHandshake::~ChildPortHandshake() {
base::ScopedFD ChildPortHandshake::ClientReadFD() {
DCHECK(client_read_fd_.is_valid());
- return client_read_fd_.Pass();
+ return crashpad::move(client_read_fd_);
}
base::ScopedFD ChildPortHandshake::ServerWriteFD() {
DCHECK(server_write_fd_.is_valid());
- return server_write_fd_.Pass();
+ return crashpad::move(server_write_fd_);
}
mach_port_t ChildPortHandshake::RunServer(PortRightType port_right_type) {
client_read_fd_.reset();
- return RunServerForFD(server_write_fd_.Pass(), port_right_type);
+ return RunServerForFD(crashpad::move(server_write_fd_), port_right_type);
}
bool ChildPortHandshake::RunClient(mach_port_t port,
mach_msg_type_name_t right_type) {
server_write_fd_.reset();
- return RunClientForFD(client_read_fd_.Pass(), port, right_type);
+ return RunClientForFD(crashpad::move(client_read_fd_), port, right_type);
}
// static
mach_port_t ChildPortHandshake::RunServerForFD(base::ScopedFD server_write_fd,
PortRightType port_right_type) {
ChildPortHandshakeServer server;
- return server.RunServer(server_write_fd.Pass(), port_right_type);
+ return server.RunServer(crashpad::move(server_write_fd), port_right_type);
}
// static
« no previous file with comments | « util/mach/child_port_handshake.h ('k') | util/net/http_transport.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698