From 5eedd365d41fc8e3e75c8fe63de08eef70d4b0dd Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Tue, 5 Nov 2019 13:36:40 +1100 Subject: [PATCH] Insist that kasp is not linked. --- lib/dns/kasp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/dns/kasp.c b/lib/dns/kasp.c index 66938d91e4..1784b46be0 100644 --- a/lib/dns/kasp.c +++ b/lib/dns/kasp.c @@ -82,6 +82,8 @@ destroy(dns_kasp_t *kasp) { dns_kasp_key_t *key; dns_kasp_key_t *key_next; + ISC_INSIST(!ISC_LINK_LINKED(kasp, link)); + for (key = ISC_LIST_HEAD(kasp->keys); key != NULL; key = key_next) { key_next = ISC_LIST_NEXT(key, link); ISC_LIST_UNLINK(kasp->keys, key, link);