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

Unified Diff: net/socket/transport_client_socket_pool.h

Issue 1096203006: Collect all ConnectionAttempts from both sockets in TransportConnectJob. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@domrel_serverip1
Patch Set: Return fake ConnectionAttempt in MockTCPClientSocket Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/socket/tcp_client_socket.cc ('k') | net/socket/transport_client_socket_pool.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/transport_client_socket_pool.h
diff --git a/net/socket/transport_client_socket_pool.h b/net/socket/transport_client_socket_pool.h
index de57d18aa80f803c24ddce436fce8d11035b306f..c2c8ab2a8a617a121eaba02b6578a269ef66e172 100644
--- a/net/socket/transport_client_socket_pool.h
+++ b/net/socket/transport_client_socket_pool.h
@@ -17,6 +17,7 @@
#include "net/dns/single_request_host_resolver.h"
#include "net/socket/client_socket_pool.h"
#include "net/socket/client_socket_pool_base.h"
+#include "net/socket/connection_attempts.h"
namespace net {
@@ -196,6 +197,8 @@ class NET_EXPORT_PRIVATE TransportConnectJob : public ConnectJob {
// Otherwise, it returns a net error code.
int ConnectInternal() override;
+ void CopyConnectionAttemptsFromSockets();
+
TransportConnectJobHelper helper_;
scoped_ptr<StreamSocket> transport_socket_;
@@ -209,7 +212,14 @@ class NET_EXPORT_PRIVATE TransportConnectJob : public ConnectJob {
ConnectInterval interval_between_connects_;
int resolve_result_;
- int connect_result_;
+
+ // Used in the failure case to save connection attempts made on the main and
+ // fallback sockets and pass them on in |GetAdditionalErrorState|. (In the
+ // success case, connection attempts are passed through the returned socket;
+ // attempts are copied from the other socket, if one exists, into it before
+ // it is returned.)
+ ConnectionAttempts connection_attempts_;
+ ConnectionAttempts fallback_connection_attempts_;
DISALLOW_COPY_AND_ASSIGN(TransportConnectJob);
};
« no previous file with comments | « net/socket/tcp_client_socket.cc ('k') | net/socket/transport_client_socket_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698