From: Remi Gacogne Date: Mon, 16 Jan 2017 17:05:34 +0000 (+0100) Subject: Explicitely use const iterators in `validateWithKeySet` and `getKeysFor` X-Git-Tag: rec-4.0.5-rc1~10^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F5045%2Fhead;p=thirdparty%2Fpdns.git Explicitely use const iterators in `validateWithKeySet` and `getKeysFor` (cherry picked from commit 7a4f4632913046afde9e8acbbff1213b8faf982d) --- diff --git a/pdns/validate.cc b/pdns/validate.cc index 27f7114f88..fa209074a4 100644 --- a/pdns/validate.cc +++ b/pdns/validate.cc @@ -151,7 +151,7 @@ void validateWithKeySet(const cspmap_t& rrsets, cspmap_t& validated, const keyse cerr<<"\tTag: "< "<first.first)<<"/"<first.second)<<" with "<second.signatures.size()<<" sigs"<second.signatures) { vector > toSign = i->second.records; @@ -281,7 +281,7 @@ vState getKeysFor(DNSRecordOracle& dro, const DNSName& zone, keyset_t &keyset) LOG(" => "< sigs; vector > toSign; @@ -367,7 +367,7 @@ vState getKeysFor(DNSRecordOracle& dro, const DNSName& zone, keyset_t &keyset) // but not a fully validated DNSKEY set, yet // one of these valid DNSKEYs should be able to validate the // whole set - for(auto i=sigs.begin(); i!=sigs.end(); i++) + for(auto i=sigs.cbegin(); i!=sigs.cend(); i++) { // cerr<<"got sig for keytag "<d_tag<<" matching "<d_tag).size()<<" keys of which "<d_tag).size()<<" valid"<