diff options
Diffstat (limited to 'netwerk/protocol/http/nsHttpTransaction.cpp')
-rw-r--r-- | netwerk/protocol/http/nsHttpTransaction.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/netwerk/protocol/http/nsHttpTransaction.cpp b/netwerk/protocol/http/nsHttpTransaction.cpp index bc182c6cd..706710d89 100644 --- a/netwerk/protocol/http/nsHttpTransaction.cpp +++ b/netwerk/protocol/http/nsHttpTransaction.cpp @@ -623,6 +623,14 @@ nsHttpTransaction::OnTransportStatus(nsITransport* transport, } else if (status == NS_NET_STATUS_CONNECTED_TO) { SetConnectEnd(TimeStamp::Now(), true); } else if (status == NS_NET_STATUS_TLS_HANDSHAKE_ENDED) { + { + // before overwriting connectEnd, copy it to secureConnectionStart + MutexAutoLock lock(mLock); + if (mTimings.secureConnectionStart.IsNull() && + !mTimings.connectEnd.IsNull()) { + mTimings.secureConnectionStart = mTimings.connectEnd; + } + } SetConnectEnd(TimeStamp::Now(), false); } } @@ -2136,6 +2144,13 @@ nsHttpTransaction::Timings() } void +nsHttpTransaction::BootstrapTimings(TimingStruct times) +{ + mozilla::MutexAutoLock lock(mLock); + mTimings = times; +} + +void nsHttpTransaction::SetDomainLookupStart(mozilla::TimeStamp timeStamp, bool onlyIfNull) { mozilla::MutexAutoLock lock(mLock); @@ -2227,6 +2242,13 @@ nsHttpTransaction::GetConnectStart() } mozilla::TimeStamp +nsHttpTransaction::GetSecureConnectionStart() +{ + mozilla::MutexAutoLock lock(mLock); + return mTimings.secureConnectionStart; +} + +mozilla::TimeStamp nsHttpTransaction::GetConnectEnd() { mozilla::MutexAutoLock lock(mLock); |