summaryrefslogtreecommitdiff
path: root/usr.sbin/bind/lib/dns/dst_api.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/bind/lib/dns/dst_api.c')
-rw-r--r--usr.sbin/bind/lib/dns/dst_api.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.sbin/bind/lib/dns/dst_api.c b/usr.sbin/bind/lib/dns/dst_api.c
index 43615971626..805d9ec2fe9 100644
--- a/usr.sbin/bind/lib/dns/dst_api.c
+++ b/usr.sbin/bind/lib/dns/dst_api.c
@@ -1,5 +1,5 @@
/*
- * Portions Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
+ * Portions Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Portions Copyright (C) 1999-2003 Internet Software Consortium.
* Portions Copyright (C) 1995-2000 by Network Associates, Inc.
*
@@ -18,7 +18,7 @@
/*
* Principal Author: Brian Wellington
- * $ISC: dst_api.c,v 1.1.4.1 2004/12/09 04:07:16 marka Exp $
+ * $ISC: dst_api.c,v 1.1.4.3 2006/01/04 23:50:20 marka Exp $
*/
#include <config.h>
@@ -1027,8 +1027,10 @@ write_public_key(const dst_key_t *key, int type, const char *directory) {
}
ret = dns_name_print(key->key_name, fp);
- if (ret != ISC_R_SUCCESS)
+ if (ret != ISC_R_SUCCESS) {
+ fclose(fp);
return (ret);
+ }
fprintf(fp, " ");