Commit Diff
Diff:
3a6eec2dec071db1a1b9a62ece376fa05a5a3b11
6cd9729860d4b5a8981b50f24da0dec19d048737
Commit:
6cd9729860d4b5a8981b50f24da0dec19d048737
Tree:
2de7dee459ee8266dda39aed7779b14ac5cfbfc8
Author:
pjp <pjp@delphinusdns.org>
Committer:
pjp <pjp@delphinusdns.org>
Date:
Sat Jul 18 10:49:25 2020 UTC
Message:
I don't know if this is a dead/unused function but convert_name was used wrongly here by not freeing when returning with error..
blob - 5c6143caf5ce61d85ed252dc4b1a28a4f766e726
blob + 5b744f49f54c83babfd5ec6b64087f7a5fb6291b
--- dnssec.c
+++ dnssec.c
@@ -27,7 +27,7 @@
*/
/*
- * $Id: dnssec.c,v 1.29 2020/07/16 12:02:38 pjp Exp $
+ * $Id: dnssec.c,v 1.30 2020/07/18 10:49:25 pjp Exp $
*/
#include <sys/types.h>
@@ -401,6 +401,7 @@ find_nsec(char *name, int namelen, struct rbtree *rbt,
rrp = TAILQ_FIRST(&rrset->rr_head);
if (rrp == NULL) {
+ free(nsecname);
free(humanname);
return (NULL);
}
@@ -434,12 +435,14 @@ find_nsec(char *name, int namelen, struct rbtree *rbt,
rbt0 = find_rrset(db, tmpname, tmplen);
if (rbt0 == NULL) {
+ free (nsecname);
free (humanname);
free (table);
return (NULL);
}
if ((rrset = find_rr(rbt0, DNS_TYPE_NSEC)) == NULL) {
+ free (nsecname);
free (humanname);
free (table);
return (NULL);
repomaster@centroid.eu