]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Only erase if we know the edns entry exists
authorOtto Moerbeek <otto.moerbeek@open-xchange.com>
Fri, 17 Jun 2022 11:46:31 +0000 (13:46 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Fri, 17 Jun 2022 11:46:31 +0000 (13:46 +0200)
pdns/syncres.cc

index 15fbbed165ee7e7695b476953f3962d84cc3e5b1..3745042addfbaf5376131c555001e2d908be724c 100644 (file)
@@ -1567,7 +1567,10 @@ LWResult::Result SyncRes::asyncresolveWrapper(const ComboAddress& ip, bool ednsM
         lock->setMode(ind, ednsstatus, EDNSStatus::EDNSIGNORANT, d_now.tv_sec);
       }
       else {
-        lock->erase(ip);
+        // New status is EDNSOK
+        if (ednsstatus != lock->end()) {
+          lock->erase(ip);
+        }
       }
     }