]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
cache: restored kr_cache_insert_rr API
authorMarek Vavruša <mvavrusa@cloudflare.com>
Mon, 12 Mar 2018 04:04:19 +0000 (21:04 -0700)
committerMarek Vavruša <mvavrusa@cloudflare.com>
Fri, 7 Sep 2018 17:45:21 +0000 (10:45 -0700)
This commit abstracts out stash_rrset from stash_rrarray_entry,
and fixes incrementing metrics on actual record insertion.
It then resurfaces kr_cache_insert_rr that was deleted in 2.0
using the extracted function.

lib/cache/api.c

index 34b89b9d5aea86fd828f5eb39da36fb1d3716bbc..1c8bf977b2783d88751d81708492a618bad666de 100644 (file)
@@ -54,7 +54,6 @@ static const uint16_t CACHE_VERSION = 5;
 #define KEY_HSIZE (sizeof(uint8_t) + sizeof(uint16_t))
 #define KEY_SIZE (KEY_HSIZE + KNOT_DNAME_MAXLEN)
 
-
 /** @internal Forward declarations of the implementation details
  * \param optout[out] Set *optout = true; when encountering an opt-out NSEC3 (optional). */
 static ssize_t stash_rrset(struct kr_cache *cache, const struct kr_query *qry,