Commit c2a34db2 authored by Jelte Jansen's avatar Jelte Jansen
Browse files

[master] fix RRset cache update and re-enable test

parent 98908690
......@@ -76,11 +76,10 @@ RRsetCache::update(const isc::dns::RRset& rrset, const RRsetTrustLevel& level) {
return (entry_ptr);
} else {
HashKey key = entry_ptr->hashKey();
rrset_table_.remove(key);
entry_ptr.reset(new RRsetEntry(rrset, level));
//TODO, lru list touch.
// Replace the expired rrset entry if it exists.
rrset_table_.add(entry_ptr, key, true);
rrset_table_.add(entry_ptr, entry_ptr->hashKey(), true);
return (entry_ptr);
}
}
......
......@@ -78,7 +78,7 @@ TEST_F(MessageCacheTest, testLookup) {
EXPECT_TRUE(message_cache_->lookup(qname1, RRType::A(), message_render));
}
TEST_F(MessageCacheTest, DISABLED_testUpdate) {
TEST_F(MessageCacheTest, testUpdate) {
messageFromFile(message_parse, "message_fromWire4");
EXPECT_TRUE(message_cache_->update(message_parse));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment