From: Peter van Dijk Date: Fri, 1 Oct 2021 15:52:39 +0000 (+0200) Subject: reduce back and forth type conversions; beter var naming X-Git-Tag: auth-4.6.0-alpha1~6^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F10562%2Fhead;p=thirdparty%2Fpdns.git reduce back and forth type conversions; beter var naming --- diff --git a/pdns/mastercommunicator.cc b/pdns/mastercommunicator.cc index 7bd71f476f..21b0488bab 100644 --- a/pdns/mastercommunicator.cc +++ b/pdns/mastercommunicator.cc @@ -46,28 +46,27 @@ void CommunicatorClass::queueNotifyDomain(const DomainInfo& di, UeberBackend* B) { bool hasQueuedItem=false; - set nsset, ips; + set ips; + set nsset; DNSZoneRecord rr; FindNS fns; - try { if (d_onlyNotify.size()) { B->lookup(QType(QType::NS), di.zone, di.id); while(B->get(rr)) - nsset.insert(getRR(rr.dr)->getNS().toString()); + nsset.insert(getRR(rr.dr)->getNS()); - for(const auto & j : nsset) { - auto dnsj = DNSName(j); - vector nsips=fns.lookup(dnsj, B); + for(const auto & ns : nsset) { + vector nsips=fns.lookup(ns, B); if(nsips.empty()) - g_log<