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

Unified Diff: net/quic/quic_stream_factory.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/quic/quic_http_utils.cc ('k') | net/quic/test_tools/crypto_test_utils_chromium.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_stream_factory.cc
diff --git a/net/quic/quic_stream_factory.cc b/net/quic/quic_stream_factory.cc
index 976cfcf46f76527c065f26b6a22e207b3ea111f6..e48985d2ef323b1bba210ba73b29e604b6ee6b6e 100644
--- a/net/quic/quic_stream_factory.cc
+++ b/net/quic/quic_stream_factory.cc
@@ -6,6 +6,7 @@
#include <algorithm>
#include <set>
+#include <utility>
#include "base/location.h"
#include "base/macros.h"
@@ -428,7 +429,7 @@ int QuicStreamFactory::Job::DoConnect() {
io_state_ = STATE_CONNECT_COMPLETE;
int rv = factory_->CreateSession(
- server_id_, cert_verify_flags_, server_info_.Pass(), address_list_,
+ server_id_, cert_verify_flags_, std::move(server_info_), address_list_,
dns_resolution_end_time_, net_log_, &session_);
if (rv != OK) {
DCHECK(rv != ERR_IO_PENDING);
@@ -518,7 +519,7 @@ int QuicStreamRequest::Request(const HostPortPair& host_port_pair,
void QuicStreamRequest::set_stream(scoped_ptr<QuicHttpStream> stream) {
DCHECK(stream);
- stream_ = stream.Pass();
+ stream_ = std::move(stream);
}
void QuicStreamRequest::OnRequestComplete(int rv) {
@@ -535,7 +536,7 @@ base::TimeDelta QuicStreamRequest::GetTimeDelayForWaitingJob() const {
scoped_ptr<QuicHttpStream> QuicStreamRequest::ReleaseStream() {
DCHECK(stream_);
- return stream_.Pass();
+ return std::move(stream_);
}
QuicStreamFactory::QuicStreamFactory(
@@ -1134,7 +1135,7 @@ scoped_ptr<base::Value> QuicStreamFactory::QuicStreamFactoryInfoToValue()
list->Append(session->GetInfoAsValue(hosts));
}
}
- return list.Pass();
+ return std::move(list);
}
void QuicStreamFactory::ClearCachedStatesInCryptoConfig() {
@@ -1296,12 +1297,12 @@ int QuicStreamFactory::CreateSession(const QuicServerId& server_id,
}
*session = new QuicChromiumClientSession(
- connection, socket.Pass(), this, quic_crypto_client_stream_factory_,
- clock_.get(), transport_security_state_, server_info.Pass(), server_id,
- yield_after_packets_, yield_after_duration_, cert_verify_flags, config,
- &crypto_config_, network_connection_.GetDescription(),
+ connection, std::move(socket), this, quic_crypto_client_stream_factory_,
+ clock_.get(), transport_security_state_, std::move(server_info),
+ server_id, yield_after_packets_, yield_after_duration_, cert_verify_flags,
+ config, &crypto_config_, network_connection_.GetDescription(),
dns_resolution_end_time, base::ThreadTaskRunnerHandle::Get().get(),
- socket_performance_watcher.Pass(), net_log.net_log());
+ std::move(socket_performance_watcher), net_log.net_log());
all_sessions_[*session] = server_id; // owning pointer
« no previous file with comments | « net/quic/quic_http_utils.cc ('k') | net/quic/test_tools/crypto_test_utils_chromium.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698