From: Charles-Henri Bruyand Date: Thu, 13 Dec 2018 16:47:53 +0000 (+0100) Subject: Remove unused variables X-Git-Tag: rec-4.2.0-alpha1~49^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7f95a941d67683da783a1b824eb469579cef5e56;p=thirdparty%2Fpdns.git Remove unused variables --- diff --git a/pdns/comfun.cc b/pdns/comfun.cc index aacab3cc70..c78ebd81aa 100644 --- a/pdns/comfun.cc +++ b/pdns/comfun.cc @@ -519,7 +519,6 @@ try ZoneParserTNG zpt(argv[2]); DNSResourceRecord rr; - unsigned int pdnscount=0; set seen, pdnsdomains; int count=0; while(zpt.get(rr)) { @@ -527,7 +526,6 @@ try seen.insert(rr.qname); } if(rr.qtype.getCode() == QType::NS && powerdns.count(DNSName(rr.content)) && !pdnsdomains.count(DNSName(rr.qname))) { - pdnscount++; pdnsdomains.insert(DNSName(rr.qname)); } if(!(count%100000)) { diff --git a/pdns/ixfrdist.cc b/pdns/ixfrdist.cc index b3065704cb..1ba8ffed0c 100644 --- a/pdns/ixfrdist.cc +++ b/pdns/ixfrdist.cc @@ -561,8 +561,8 @@ static bool sendPacketOverTCP(int fd, const std::vector& packet) sendBuf[0]=packet.size()/256; sendBuf[1]=packet.size()%256; - ssize_t send = writen2(fd, sendBuf, 2); - send += writen2(fd, &packet[0], packet.size()); + writen2(fd, sendBuf, 2); + writen2(fd, &packet[0], packet.size()); return true; } diff --git a/pdns/ixfrutils.cc b/pdns/ixfrutils.cc index df4e8500dc..e20cfe666b 100644 --- a/pdns/ixfrutils.cc +++ b/pdns/ixfrutils.cc @@ -143,9 +143,7 @@ void loadZoneFromDisk(records_t& records, const string& fname, const DNSName& zo DNSResourceRecord rr; bool seenSOA=false; - unsigned int nrecords=0; while(zpt.get(rr)) { - ++nrecords; if(rr.qtype.getCode() == QType::CNAME && rr.content.empty()) rr.content="."; rr.qname = rr.qname.makeRelative(zone);