| Index: net/socket/tcp_client_socket_libevent.cc
|
| ===================================================================
|
| --- net/socket/tcp_client_socket_libevent.cc (revision 86260)
|
| +++ net/socket/tcp_client_socket_libevent.cc (working copy)
|
| @@ -219,6 +219,7 @@
|
|
|
| // Connect the socket.
|
| if (!use_tcp_fastopen_) {
|
| + connect_start_time_ = base::Time::Now();
|
| if (!HANDLE_EINTR(connect(socket_, current_ai_->ai_addr,
|
| static_cast<int>(current_ai_->ai_addrlen)))) {
|
| // Connected without waiting!
|
| @@ -260,6 +261,9 @@
|
| write_socket_watcher_.StopWatchingFileDescriptor();
|
|
|
| if (result == OK) {
|
| + rtt_ms_ = static_cast<double>((base::Time::Now() -
|
| + connect_start_time_).InMicroseconds())
|
| + / 1000.0;
|
| use_history_.set_was_ever_connected();
|
| return OK; // Done!
|
| }
|
| @@ -349,6 +353,7 @@
|
| if (nread >= 0) {
|
| base::StatsCounter read_bytes("tcp.read_bytes");
|
| read_bytes.Add(nread);
|
| + num_bytes_read_ += nread;
|
| if (nread > 0)
|
| use_history_.set_was_used_to_convey_data();
|
| LogByteTransfer(
|
|
|