Commit 6d36fc6b authored by Jan Včelák's avatar Jan Včelák 🚀

dnssec: fix memory leak in KASP zone freeing

parent 95e9dad7
......@@ -56,6 +56,7 @@ static void free_kasp_key(void *data, void *ctx _unused_)
dnssec_kasp_key_t *kasp_key = data;
dnssec_key_free(kasp_key->key);
free(kasp_key->id);
free(kasp_key);
}
......
......@@ -891,7 +891,7 @@ static int cmd_zone_key_generate(int argc, char *argv[])
config.timing.created = time(NULL);
if (!zone_add_dnskey(zone, keyid, dnskey, &config.timing)) {
free(dnskey);
dnssec_key_free(dnskey);
return 1;
}
......
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