iter->d_pbdata = std::move(*pbdata);
}
- break;
+ return;
}
- if (iter == range.second) { // nothing to refresh
- struct Entry e(qname, std::move(responsePacket), std::move(query), tcp);
- e.d_qhash = qhash;
- e.d_type = qtype;
- e.d_class = qclass;
- e.d_ttd = now + ttl;
- e.d_creation = now;
- e.d_tag = tag;
- e.d_vstate = valState;
- if (pbdata) {
- e.d_pbdata = std::move(*pbdata);
- }
-
- d_packetCache.insert(e);
+ struct Entry e(qname, std::move(responsePacket), std::move(query), tcp);
+ e.d_qhash = qhash;
+ e.d_type = qtype;
+ e.d_class = qclass;
+ e.d_ttd = now + ttl;
+ e.d_creation = now;
+ e.d_tag = tag;
+ e.d_vstate = valState;
+ if (pbdata) {
+ e.d_pbdata = std::move(*pbdata);
}
+
+ d_packetCache.insert(e);
}
uint64_t RecursorPacketCache::size()
// Again to check cache
try {
- res = sr->beginResolve(target, QType(QType::A), QClass::IN, ret);
+ sr->beginResolve(target, QType(QType::A), QClass::IN, ret);
BOOST_CHECK(false);
}
catch (const ImmediateServFailException& ex) {
// And again to check cache
try {
- res = sr->beginResolve(target1, QType(QType::A), QClass::IN, ret);
+ sr->beginResolve(target1, QType(QType::A), QClass::IN, ret);
BOOST_CHECK(false);
}
catch (const ImmediateServFailException& ex) {
logger->error(Logr::Warning, err, "Unable to open file pointer"));
return false;
}
- fd = -1;
try {
newZone->dump(fp.get());