From: Marek VavruĊĦa Date: Fri, 29 May 2015 21:54:45 +0000 (+0200) Subject: layer/pktcache: do not take TTLMIN into account X-Git-Tag: v1.0.0-beta1~125^2~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=60db26935b9eddb1d1ddfb78eb4625bf3eef450d;p=thirdparty%2Fknot-resolver.git layer/pktcache: do not take TTLMIN into account --- diff --git a/lib/layer/pktcache.c b/lib/layer/pktcache.c index 66c8059a2..50ba170ec 100644 --- a/lib/layer/pktcache.c +++ b/lib/layer/pktcache.c @@ -137,15 +137,6 @@ static uint32_t packet_ttl(knot_pkt_t *pkt) { bool has_ttl = false; uint32_t ttl = UINT32_MAX; - /* Fetch SOA from authority. */ - const knot_pktsection_t *ns = knot_pkt_section(pkt, KNOT_AUTHORITY); - for (unsigned i = 0; i < ns->count; ++i) { - const knot_rrset_t *rr = knot_pkt_rr(ns, i); - if (rr->type == KNOT_RRTYPE_SOA) { - ttl = knot_soa_minimum(&rr->rrs); - break; - } - } /* Get minimum entry TTL in the packet */ for (knot_section_t i = KNOT_ANSWER; i <= KNOT_ADDITIONAL; ++i) { const knot_pktsection_t *sec = knot_pkt_section(pkt, i);