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

Unified Diff: net/socket/tcp_socket_win.cc

Issue 850793004: Update from https://crrev.com/311346 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_unacked_packet_map.cc ('k') | net/spdy/spdy_session.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/tcp_socket_win.cc
diff --git a/net/socket/tcp_socket_win.cc b/net/socket/tcp_socket_win.cc
index 1a4f2e89728fa027f9f541e1855b76153390bc32..0031c638165c61c8a8fe137bcfaa16c748ca876c 100644
--- a/net/socket/tcp_socket_win.cc
+++ b/net/socket/tcp_socket_win.cc
@@ -812,6 +812,11 @@ int TCPSocketWin::DoConnect() {
CreateNetLogIPEndPointCallback(peer_address_.get()));
core_ = new Core(this);
+
+ // TODO(vadimt): Remove ScopedTracker below once crbug.com/436634 is fixed.
+ tracked_objects::ScopedTracker tracking_profile1(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION("436634 TCPSocketWin::DoConnect1"));
+
// WSAEventSelect sets the socket to non-blocking mode as a side effect.
// Our connect() and recv() calls require that the socket be non-blocking.
WSAEventSelect(socket_, core_->read_overlapped_.hEvent, FD_CONNECT);
@@ -819,7 +824,16 @@ int TCPSocketWin::DoConnect() {
SockaddrStorage storage;
if (!peer_address_->ToSockAddr(storage.addr, &storage.addr_len))
return ERR_ADDRESS_INVALID;
+
+ // TODO(vadimt): Remove ScopedTracker below once crbug.com/436634 is fixed.
+ tracked_objects::ScopedTracker tracking_profile2(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION("436634 TCPSocketWin::DoConnect2"));
+
if (!connect(socket_, storage.addr, storage.addr_len)) {
+ // TODO(vadimt): Remove ScopedTracker below once crbug.com/436634 is fixed.
+ tracked_objects::ScopedTracker tracking_profile3(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION("436634 TCPSocketWin::DoConnect3"));
+
// Connected without waiting!
//
// The MSDN page for connect says:
@@ -836,6 +850,11 @@ int TCPSocketWin::DoConnect() {
return OK;
} else {
int os_error = WSAGetLastError();
+
+ // TODO(vadimt): Remove ScopedTracker below once crbug.com/436634 is fixed.
+ tracked_objects::ScopedTracker tracking_profile4(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION("436634 TCPSocketWin::DoConnect4"));
+
if (os_error != WSAEWOULDBLOCK) {
LOG(ERROR) << "connect failed: " << os_error;
connect_os_error_ = os_error;
@@ -845,6 +864,10 @@ int TCPSocketWin::DoConnect() {
}
}
+ // TODO(vadimt): Remove ScopedTracker below once crbug.com/436634 is fixed.
+ tracked_objects::ScopedTracker tracking_profile5(
+ FROM_HERE_WITH_EXPLICIT_FUNCTION("436634 TCPSocketWin::DoConnect5"));
+
core_->WatchForRead();
return ERR_IO_PENDING;
}
« no previous file with comments | « net/quic/quic_unacked_packet_map.cc ('k') | net/spdy/spdy_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698