From 0e0d2891c08b70886f811d627bfb91a0c5e07dfc Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Mon, 5 Jan 2004 04:21:30 +0000 Subject: [PATCH] 1545. [bug] It was possible to leak memory if named was unable to bind to the specified transfer source and TSIG was being used. [RT #10120] --- CHANGES | 4 ++++ lib/dns/zone.c | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/CHANGES b/CHANGES index 3d00a88092..48b3fe212d 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,7 @@ +1545. [bug] It was possible to leak memory if named was unable to + bind to the specified transfer source and TSIG was + being used. [RT #10120] + 1544. [placeholder] rt10147 1543. [placeholder] rt10147 diff --git a/lib/dns/zone.c b/lib/dns/zone.c index fb8b889255..65ff103346 100644 --- a/lib/dns/zone.c +++ b/lib/dns/zone.c @@ -15,7 +15,7 @@ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: zone.c,v 1.402 2003/11/04 05:23:31 marka Exp $ */ +/* $Id: zone.c,v 1.403 2004/01/05 04:21:30 marka Exp $ */ #include @@ -3947,11 +3947,11 @@ soa_query(isc_task_t *task, isc_event_t *event) { dns_result_totext(result)); goto cleanup; } - if (key != NULL) - dns_tsigkey_detach(&key); cancel = ISC_FALSE; cleanup: + if (key != NULL) + dns_tsigkey_detach(&key); if (result != ISC_R_SUCCESS) DNS_ZONE_CLRFLAG(zone, DNS_ZONEFLG_REFRESH); if (message != NULL)