From c079ae340c02a16f1b0128185bb0ceef1a09bd8b Mon Sep 17 00:00:00 2001 From: Peter van Dijk Date: Mon, 8 Jul 2019 11:16:30 +0200 Subject: [PATCH] Revert "A way to fix https://github.com/PowerDNS/pdns/issues/7646. It might" This reverts commit 475fc44ee8d1fc21bb9fe0beffa5fd5b1799277f. --- pdns/communicator.hh | 23 ++++------------------- 1 file changed, 4 insertions(+), 19 deletions(-) diff --git a/pdns/communicator.hh b/pdns/communicator.hh index 2cb0f70fe..5413e4dac 100644 --- a/pdns/communicator.hh +++ b/pdns/communicator.hh @@ -259,25 +259,10 @@ public: if(b) { b->lookup(QType(QType::ANY),name); - bool ok; - do { - DNSZoneRecord rr; - try { - ok = b->get(rr); - } - catch (PDNSException &ae) { - g_log << Logger::Error << "Skipping record: " << ae.reason << endl; - continue; - } - catch (std::exception &e) { - g_log << Logger::Error << "Skipping record: " << e.what() << endl; - continue; - } - if (ok) { - if (rr.dr.d_type == QType::A || rr.dr.d_type == QType::AAAA) - addresses.push_back(rr.dr.d_content->getZoneRepresentation()); // SOL if you have a CNAME for an NS - } - } while (ok); + DNSZoneRecord rr; + while(b->get(rr)) + if(rr.dr.d_type == QType::A || rr.dr.d_type==QType::AAAA) + addresses.push_back(rr.dr.d_content->getZoneRepresentation()); // SOL if you have a CNAME for an NS } return addresses; } -- 2.40.0