summaryrefslogtreecommitdiffstats
path: root/dns.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2003-05-15 13:27:28 +1000
committerDamien Miller <djm@mindrot.org>2003-05-15 13:27:28 +1000
commitb0622653baa8e4136e116945fdd1c393ab0eaba3 (patch)
tree8b4ebb7caee7a4d22eb43250ff19d987318f840d /dns.c
parent5975cf12c309735fe3fd6a81782d46a11d166437 (diff)
- jakob@cvs.openbsd.org 2003/05/15 02:27:15
[dns.c] add missing freerrset
Diffstat (limited to 'dns.c')
-rw-r--r--dns.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/dns.c b/dns.c
index 9b7a0e7a..14ca13a4 100644
--- a/dns.c
+++ b/dns.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dns.c,v 1.4 2003/05/14 23:29:22 jakob Exp $ */
+/* $OpenBSD: dns.c,v 1.5 2003/05/15 02:27:15 jakob Exp $ */
/*
* Copyright (c) 2003 Wesley Griffin. All rights reserved.
@@ -44,7 +44,7 @@
#include "uuencode.h"
extern char *__progname;
-RCSID("$OpenBSD: dns.c,v 1.4 2003/05/14 23:29:22 jakob Exp $");
+RCSID("$OpenBSD: dns.c,v 1.5 2003/05/15 02:27:15 jakob Exp $");
#ifndef LWRES
static const char *errset_text[] = {
@@ -183,6 +183,7 @@ verify_host_key_dns(const char *hostname, struct sockaddr *address,
/* Only accept validated answers */
if (!fingerprints->rri_flags & RRSET_VALIDATED) {
error("Ignored unvalidated fingerprint from DNS.");
+ freerrset(fingerprints);
return DNS_VERIFY_ERROR;
}
#endif
@@ -193,6 +194,7 @@ verify_host_key_dns(const char *hostname, struct sockaddr *address,
if (!dns_read_key(&hostkey_algorithm, &hostkey_digest_type,
&hostkey_digest, &hostkey_digest_len, hostkey)) {
error("Error calculating host key fingerprint.");
+ freerrset(fingerprints);
return DNS_VERIFY_ERROR;
}