Closed
Bug 1750209
Opened 3 years ago
Closed 3 years ago
Assertion in nsHostResolver::CompleteLookupLocked when steering and TRR mode 2.5 is used
Categories
(Core :: Networking: DNS, defect, P2)
Core
Networking: DNS
Tracking
()
RESOLVED
FIXED
98 Branch
Tracking | Status | |
---|---|---|
firefox98 | --- | fixed |
People
(Reporter: dragana, Assigned: valentin)
References
(Blocks 1 open bug)
Details
(Whiteboard: [necko-triaged])
Attachments
(1 file)
(deleted),
text/x-phabricator-request
|
Details |
Testing steering I hit this assertion:
https://searchfox.org/mozilla-central/rev/3de56eb5f266f523340e739ae1b53258e0a95dfe/netwerk/dns/nsHostResolver.cpp#1432
Comment 1•3 years ago
|
||
I also filed bug 1750154 for this.
Assignee | ||
Updated•3 years ago
|
Assignee: nobody → valentin.gosu
Comment 3•3 years ago
|
||
I think the problem here is that the return value of NativeLookup
or TrrLookup
is ignored. MaybeRetryTRRLookup
should not return true when it didn't retry anything.
FWIW, I have a WIP patch below.
diff --git a/netwerk/dns/nsHostResolver.cpp b/netwerk/dns/nsHostResolver.cpp
index c8da615b8660..781ab7d846b5 100644
--- a/netwerk/dns/nsHostResolver.cpp
+++ b/netwerk/dns/nsHostResolver.cpp
@@ -1323,8 +1323,7 @@ bool nsHostResolver::MaybeRetryTRRLookup(
MOZ_ASSERT(!aAddrRec->mResolving);
if (!StaticPrefs::network_trr_strict_native_fallback()) {
LOG(("nsHostResolver::MaybeRetryTRRLookup retrying with native"));
- NativeLookup(aAddrRec, aLock);
- return true;
+ return NS_SUCCEEDED(NativeLookup(aAddrRec, aLock));
}
if (aFirstAttemptSkipReason == TRRSkippedReason::TRR_NXDOMAIN ||
@@ -1334,8 +1333,7 @@ bool nsHostResolver::MaybeRetryTRRLookup(
("nsHostResolver::MaybeRetryTRRLookup retrying with native in strict "
"mode, skip reason was %d",
static_cast<uint32_t>(aFirstAttemptSkipReason)));
- NativeLookup(aAddrRec, aLock);
- return true;
+ return NS_SUCCEEDED(NativeLookup(aAddrRec, aLock));
}
if (aAddrRec->mTrrAttempts > 1) {
@@ -1354,9 +1352,13 @@ bool nsHostResolver::MaybeRetryTRRLookup(
auto trrQuery = aAddrRec->mTRRQuery.Lock();
trrQuery.ref() = nullptr;
}
- aAddrRec->NotifyRetryingTrr();
- TrrLookup(aAddrRec, aLock, nullptr /* pushedTRR */);
- return true;
+
+ if (NS_SUCCEEDED(TrrLookup(aAddrRec, aLock, nullptr /* pushedTRR */))) {
+ aAddrRec->NotifyRetryingTrr();
+ return true;
+ }
+
+ return false;
}
//
Assignee | ||
Comment 4•3 years ago
|
||
Pushed by valentin.gosu@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/6ee30c962971
Check return values in MaybeRetryTRRLookup r=necko-reviewers,kershaw
Comment 6•3 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 3 years ago
status-firefox98:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 98 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•