]> granicus.if.org Git - pdns/commitdiff
packethandler: fix easy cases of var shadowing
authorChristian Hofstaedtler <christian.hofstaedtler@deduktiva.com>
Fri, 7 Oct 2016 00:42:05 +0000 (02:42 +0200)
committerChristian Hofstaedtler <christian.hofstaedtler@deduktiva.com>
Fri, 7 Oct 2016 00:42:05 +0000 (02:42 +0200)
pdns/packethandler.cc
pdns/slavecommunicator.cc

index 043a5884af04f617ab3a2ae60c52b3f1e8fa8bc4..920530ed19cf5195f22eb85a9ee85e68d63826b7 100644 (file)
@@ -949,7 +949,7 @@ DNSPacket *PacketHandler::question(DNSPacket *p)
     DP->sendPacket(p);
   }
   if(LPE) {
-    int policyres=LPE->police(p, ret);
+    policyres = LPE->police(p, ret);
     if(policyres == PolicyDecision::DROP) {
       delete ret;
       return NULL;
index 2b8c9845d8b5906984a507f6ebb4691297b41775..56724320b812eb565db006e215fee011ca980027 100644 (file)
@@ -101,9 +101,9 @@ void CommunicatorClass::ixfrSuck(const DNSName &domain, const TSIGTriplet& tt, c
     memset(&st, 0, sizeof(st));
     st.serial=di.serial;
 
-    DNSRecord dr;
-    dr.d_content = std::make_shared<SOARecordContent>(g_rootdnsname, g_rootdnsname, st);
-    auto deltas = getIXFRDeltas(remote, domain, dr, tt, laddr.sin4.sin_family ? &laddr : 0, ((size_t) ::arg().asNum("xfr-max-received-mbytes")) * 1024 * 1024);
+    DNSRecord drsoa;
+    drsoa.d_content = std::make_shared<SOARecordContent>(g_rootdnsname, g_rootdnsname, st);
+    auto deltas = getIXFRDeltas(remote, domain, drsoa, tt, laddr.sin4.sin_family ? &laddr : 0, ((size_t) ::arg().asNum("xfr-max-received-mbytes")) * 1024 * 1024);
     zs.numDeltas=deltas.size();
     //    cout<<"Got "<<deltas.size()<<" deltas from serial "<<di.serial<<", applying.."<<endl;