]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
rec: Copy the salt into the cache instead of taking a reference
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 11 Dec 2020 15:37:49 +0000 (16:37 +0100)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 11 Dec 2020 15:37:49 +0000 (16:37 +0100)
At the moment the salt does live longer than the cache, but that
might hold true forever.

pdns/validate.cc

index f97322a29fbb6f827cb1a682e76ae08027b743c8..9b709522843996f93b240ed01980c824de9b6f08 100644 (file)
@@ -80,7 +80,7 @@ static bool nsecProvesENT(const DNSName& name, const DNSName& begin, const DNSNa
   return begin.canonCompare(name) && next != name && next.isPartOf(name);
 }
 
-using nsec3HashesCache = std::map<std::tuple<DNSName, std::string&, uint16_t>, std::string>;
+using nsec3HashesCache = std::map<std::tuple<DNSName, std::string, uint16_t>, std::string>;
 
 static std::string getHashFromNSEC3(const DNSName& qname, const std::shared_ptr<NSEC3RecordContent>& nsec3, nsec3HashesCache& cache)
 {