]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
rec: Clean up QLA
authorPieter Lexis <pieter.lexis@powerdns.com>
Wed, 10 Jun 2020 12:26:55 +0000 (14:26 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Fri, 3 Jul 2020 08:29:09 +0000 (10:29 +0200)
pdns/pdns_recursor.cc
pdns/recursordist/test-syncres_cc10.cc

index 551db20b7661ff265715b75531ff0dadd4a1407a..71ea44bb06fe2da3bf3a413aaf3c93230aaa95dc 100644 (file)
@@ -4166,7 +4166,7 @@ static int serviceMain(int argc, char*argv[])
     g_log<<Logger::Warning<<"Enabling IPv4 transport for outgoing queries"<<endl;
   }
   else {
-    g_log<<Logger::Warning<<"NOT using IPv6 for outgoing queries - add an IPv4 address (like '0.0.0.0') to query-local-address to enable"<<endl;
+    g_log<<Logger::Warning<<"NOT using IPv4 for outgoing queries - add an IPv4 address (like '0.0.0.0') to query-local-address to enable"<<endl;
   }
 
 
@@ -4178,6 +4178,11 @@ static int serviceMain(int argc, char*argv[])
     g_log<<Logger::Warning<<"NOT using IPv6 for outgoing queries - add an IPv6 address (like '::') to query-local-address to enable"<<endl;
   }
 
+  if (!(SyncRes::s_doIPv6 && SyncRes::s_doIPv4)) {
+    g_log<<Logger::Error<<"No outgoing addresses specified! Can not continue"<<endl;
+    exit(99);
+  }
+
   // keep this ABOVE loadRecursorLuaConfig!
   if(::arg()["dnssec"]=="off")
     g_dnssecmode=DNSSECMode::Off;
index c7a8708d58f089de29fb8558b222e98e67f25522..61182c3a99fc308f9042e2fe6367799d47dfad7f 100644 (file)
@@ -106,8 +106,6 @@ BOOST_AUTO_TEST_CASE(test_outgoing_v6_only_no_AAAA_in_delegation)
 
   const DNSName target("powerdns.com.");
   sr->setAsyncCallback([target, &queries](const ComboAddress& ip, const DNSName& domain, int type, bool doTCP, bool sendRDQuery, int EDNS0Level, struct timeval* now, boost::optional<Netmask>& srcmask, boost::optional<const ResolveContext&> context, LWResult* res, bool* chained) {
-    cout<<ip.toString()<<endl;
-    cout<<domain<<"|"<<type<<endl;
     queries++;
     if (isRootServer(ip)) {
       setLWResult(res, 0, false, false, true);