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

Side by Side Diff: net/socket/client_socket_factory.cc

Issue 1586833002: Convert Pass()→std::move() for iOS build. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert accidental //base change Created 4 years, 11 months 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 unified diff | Download patch
« no previous file with comments | « net/quic/test_tools/crypto_test_utils_chromium.cc ('k') | net/socket/nss_ssl_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/socket/client_socket_factory.h" 5 #include "net/socket/client_socket_factory.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/lazy_instance.h" 9 #include "base/lazy_instance.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 scoped_ptr<SSLClientSocket> CreateSSLClientSocket( 69 scoped_ptr<SSLClientSocket> CreateSSLClientSocket(
70 scoped_ptr<ClientSocketHandle> transport_socket, 70 scoped_ptr<ClientSocketHandle> transport_socket,
71 const HostPortPair& host_and_port, 71 const HostPortPair& host_and_port,
72 const SSLConfig& ssl_config, 72 const SSLConfig& ssl_config,
73 const SSLClientSocketContext& context) override { 73 const SSLClientSocketContext& context) override {
74 #if defined(USE_OPENSSL) 74 #if defined(USE_OPENSSL)
75 return scoped_ptr<SSLClientSocket>(new SSLClientSocketOpenSSL( 75 return scoped_ptr<SSLClientSocket>(new SSLClientSocketOpenSSL(
76 std::move(transport_socket), host_and_port, ssl_config, context)); 76 std::move(transport_socket), host_and_port, ssl_config, context));
77 #else 77 #else
78 return scoped_ptr<SSLClientSocket>(new SSLClientSocketNSS( 78 return scoped_ptr<SSLClientSocket>(new SSLClientSocketNSS(
79 transport_socket.Pass(), host_and_port, ssl_config, context)); 79 std::move(transport_socket), host_and_port, ssl_config, context));
80 #endif 80 #endif
81 } 81 }
82 82
83 void ClearSSLSessionCache() override { SSLClientSocket::ClearSessionCache(); } 83 void ClearSSLSessionCache() override { SSLClientSocket::ClearSessionCache(); }
84 }; 84 };
85 85
86 static base::LazyInstance<DefaultClientSocketFactory>::Leaky 86 static base::LazyInstance<DefaultClientSocketFactory>::Leaky
87 g_default_client_socket_factory = LAZY_INSTANCE_INITIALIZER; 87 g_default_client_socket_factory = LAZY_INSTANCE_INITIALIZER;
88 88
89 } // namespace 89 } // namespace
90 90
91 // static 91 // static
92 ClientSocketFactory* ClientSocketFactory::GetDefaultFactory() { 92 ClientSocketFactory* ClientSocketFactory::GetDefaultFactory() {
93 return g_default_client_socket_factory.Pointer(); 93 return g_default_client_socket_factory.Pointer();
94 } 94 }
95 95
96 } // namespace net 96 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/test_tools/crypto_test_utils_chromium.cc ('k') | net/socket/nss_ssl_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698