From 4d4d4b50d044e3bfdeb8c045060a866a986dcac0 Mon Sep 17 00:00:00 2001 From: Razvan Maries Date: Tue, 1 Dec 2020 11:17:53 +0200 Subject: [PATCH] Backed out changeset 9f21beac8249 (bug 1678614) for perma failures on test_trr.js. CLOSED TREE --- netwerk/base/nsSocketTransport2.cpp | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/netwerk/base/nsSocketTransport2.cpp b/netwerk/base/nsSocketTransport2.cpp index e415acb94579..93930bef5f90 100644 --- a/netwerk/base/nsSocketTransport2.cpp +++ b/netwerk/base/nsSocketTransport2.cpp @@ -1944,19 +1944,13 @@ bool nsSocketTransport::RecoverFromError() { mNetAddr.inet6.ip.u64[1] == 0))) { SOCKET_LOG((" TRR returned 0.0.0.0 and there are no other IPs")); } else if (trrEnabled) { - nsCOMPtr dns = do_GetService(kDNSServiceCID); - uint32_t trrMode = 0; - // If current trr mode is trr only, we should not retry. - if (dns && NS_SUCCEEDED(dns->GetCurrentTrrMode(&trrMode)) && - trrMode != 3) { - // Drop state to closed. This will trigger a new round of - // DNS resolving. Bypass the cache this time since the - // cached data came from TRR and failed already! - SOCKET_LOG((" failed to connect with TRR enabled, try w/o\n")); - mState = STATE_CLOSED; - mConnectionFlags |= DISABLE_TRR | BYPASS_CACHE | REFRESH_CACHE; - tryAgain = true; - } + // Drop state to closed. This will trigger a new round of + // DNS resolving. Bypass the cache this time since the + // cached data came from TRR and failed already! + SOCKET_LOG((" failed to connect with TRR enabled, try w/o\n")); + mState = STATE_CLOSED; + mConnectionFlags |= DISABLE_TRR | BYPASS_CACHE | REFRESH_CACHE; + tryAgain = true; } } }