From ed0e1ae6bc3df39389a24d72cf544b2437bf8340 Mon Sep 17 00:00:00 2001 From: Andreas Gustafsson Date: Thu, 7 Jun 2001 18:18:24 +0000 Subject: [PATCH] 863. [bug] If an error occurred while an outgoing zone transfer was starting up, the server could access a domain name that had already been freed when logging a message saying that the transfer was starting. [RT #1383] --- CHANGES | 7 +++++++ bin/named/xfrout.c | 7 ++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/CHANGES b/CHANGES index 43a779680e..0f465fe404 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,10 @@ + + 863. [bug] If an error occurred while an outgoing zone transfer + was starting up, the server could access a domain + name that had already been freed when logging a + message saying that the transfer was starting. + [RT #1383] + 862. [bug] Use after realloc(), non portable pointer arithmetic in grmerge(). diff --git a/bin/named/xfrout.c b/bin/named/xfrout.c index f220ae7d43..d508462ed2 100644 --- a/bin/named/xfrout.c +++ b/bin/named/xfrout.c @@ -15,7 +15,7 @@ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: xfrout.c,v 1.98 2001/05/31 00:59:46 bwelling Exp $ */ +/* $Id: xfrout.c,v 1.99 2001/06/07 18:18:24 gson Exp $ */ #include @@ -1111,6 +1111,9 @@ ns_xfr_start(ns_client_t *client, dns_rdatatype_t reqtype) { CHECK(xfr->stream->methods->first(xfr->stream)); + xfrout_log1(client, question_name, question_class, ISC_LOG_INFO, + "%s started", mnemonic); + /* * Hand the context over to sendstream(). Set xfr to NULL; * sendstream() is responsible for either passing the @@ -1118,8 +1121,6 @@ ns_xfr_start(ns_client_t *client, dns_rdatatype_t reqtype) { */ sendstream(xfr); xfr = NULL; - xfrout_log1(client, question_name, question_class, ISC_LOG_INFO, - "%s started", mnemonic); result = ISC_R_SUCCESS;