From ca8f16212f01fe99f4bf78812d7686e87be11e41 Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Thu, 18 Apr 2019 10:05:51 +0200 Subject: [PATCH] auth: Move replaced meta/key entries to the back of the expunge queue Otherwise they might get expunged very quickly while they just have been inserted. --- pdns/dbdnsseckeeper.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pdns/dbdnsseckeeper.cc b/pdns/dbdnsseckeeper.cc index e4aa0b528..4af741003 100644 --- a/pdns/dbdnsseckeeper.cc +++ b/pdns/dbdnsseckeeper.cc @@ -224,7 +224,7 @@ void DNSSECKeeper::getFromMeta(const DNSName& zname, const std::string& key, std nce.d_value = value; { WriteLock l(&s_metacachelock); - replacing_insert(s_metacache, nce); + lruReplacingInsert(s_metacache, nce); } } } @@ -514,7 +514,7 @@ DNSSECKeeper::keyset_t DNSSECKeeper::getKeys(const DNSName& zone, bool useCache) kce.d_ttd = now + ttl; { WriteLock l(&s_keycachelock); - replacing_insert(s_keycache, kce); + lruReplacingInsert(s_keycache, kce); } } -- 2.40.0