From cece60fcb351acb59b82132461a543037f481eec Mon Sep 17 00:00:00 2001 From: Christian Hofstaedtler Date: Fri, 7 Oct 2016 02:42:29 +0200 Subject: [PATCH] tcpreceiver: fix easy cases of var shadowing --- pdns/tcpreceiver.cc | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/pdns/tcpreceiver.cc b/pdns/tcpreceiver.cc index 767fda8cb..14a4e624f 100644 --- a/pdns/tcpreceiver.cc +++ b/pdns/tcpreceiver.cc @@ -320,12 +320,12 @@ void *TCPNameserver::doConnection(void *data) shared_ptr reply; shared_ptr cached= shared_ptr(new DNSPacket); if(logDNSQueries) { - string remote; - if(packet->hasEDNSSubnet()) - remote = packet->getRemote().toString() + "<-" + packet->getRealRemote().toString(); + string remote_text; + if(packet->hasEDNSSubnet()) + remote_text = packet->getRemote().toString() + "<-" + packet->getRealRemote().toString(); else - remote = packet->getRemote().toString(); - L << Logger::Notice<<"TCP Remote "<< remote <<" wants '" << packet->qdomain<<"|"<qtype.getName() << + remote_text = packet->getRemote().toString(); + L << Logger::Notice<<"TCP Remote "<< remote_text <<" wants '" << packet->qdomain<<"|"<qtype.getName() << "', do = " <d_dnssecOk <<", bufsize = "<< packet->getMaxReplyLen()<<": "; } @@ -737,11 +737,11 @@ int TCPNameserver::doAXFR(const DNSName &target, shared_ptr q, int ou vector zrrs; // Add the CDNSKEY and CDS records we created earlier - for (auto const &zrr : cds) - zrrs.push_back(zrr); + for (auto const &synth_zrr : cds) + zrrs.push_back(synth_zrr); - for (auto const &zrr : cdnskey) - zrrs.push_back(zrr); + for (auto const &synth_zrr : cdnskey) + zrrs.push_back(synth_zrr); while(sd.db->get(zrr)) { if(zrr.dr.d_name.isPartOf(target)) { -- 2.40.0