Commit 5848abe0 authored by David Benjamin's avatar David Benjamin Committed by Commit Bot

Remove unreachable null check.

It's not possible for &nested_connect_job_->connect_timing() to be null.
This is a remnant of before the socket pools were flattened. Now
SSLConnectJob always gets fresh transport sockets.

Change-Id: Ib7a680af8ce72d86d1b6fd6e7e03e4bbd8a17e77
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1696001
Auto-Submit: David Benjamin <davidben@chromium.org>
Reviewed-by: default avatarEric Roman <eroman@chromium.org>
Commit-Queue: David Benjamin <davidben@chromium.org>
Cr-Commit-Position: refs/heads/master@{#677125}
parent 8be1b63b
...@@ -334,18 +334,16 @@ int SSLConnectJob::DoSSLConnect() { ...@@ -334,18 +334,16 @@ int SSLConnectJob::DoSSLConnect() {
// Set the timeout to just the time allowed for the SSL handshake. // Set the timeout to just the time allowed for the SSL handshake.
ResetTimer(kSSLHandshakeTimeout); ResetTimer(kSSLHandshakeTimeout);
// If the handle has a fresh socket, get its connect start and DNS times. // Get the transport's connect start and DNS times.
const LoadTimingInfo::ConnectTiming* socket_connect_timing = nullptr; const LoadTimingInfo::ConnectTiming& socket_connect_timing =
socket_connect_timing = &nested_connect_job_->connect_timing(); nested_connect_job_->connect_timing();
if (socket_connect_timing) { // Overwriting |connect_start| serves two purposes - it adjusts timing so
// Overwriting |connect_start| serves two purposes - it adjusts timing so // |connect_start| doesn't include dns times, and it adjusts the time so
// |connect_start| doesn't include dns times, and it adjusts the time so // as not to include time spent waiting for an idle socket.
// as not to include time spent waiting for an idle socket. connect_timing_.connect_start = socket_connect_timing.connect_start;
connect_timing_.connect_start = socket_connect_timing->connect_start; connect_timing_.dns_start = socket_connect_timing.dns_start;
connect_timing_.dns_start = socket_connect_timing->dns_start; connect_timing_.dns_end = socket_connect_timing.dns_end;
connect_timing_.dns_end = socket_connect_timing->dns_end;
}
ssl_negotiation_started_ = true; ssl_negotiation_started_ = true;
connect_timing_.ssl_start = base::TimeTicks::Now(); connect_timing_.ssl_start = base::TimeTicks::Now();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment