]> granicus.if.org Git - pdns/commitdiff
Revert "A way to fix https://github.com/PowerDNS/pdns/issues/7646. It might"
authorPeter van Dijk <peter.van.dijk@powerdns.com>
Mon, 8 Jul 2019 09:16:30 +0000 (11:16 +0200)
committerPeter van Dijk <peter.van.dijk@powerdns.com>
Mon, 8 Jul 2019 09:16:30 +0000 (11:16 +0200)
This reverts commit 475fc44ee8d1fc21bb9fe0beffa5fd5b1799277f.

pdns/communicator.hh

index 2cb0f70feb3c5e8ed22777f62d96fce8c6421f2d..5413e4dacf2335f9a5af69276536204d776719ae 100644 (file)
@@ -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;
   }