]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
2153. [bug] nsupdate could leak memory. [RT #16691]
authorMark Andrews <marka@isc.org>
Wed, 28 Feb 2007 23:57:39 +0000 (23:57 +0000)
committerMark Andrews <marka@isc.org>
Wed, 28 Feb 2007 23:57:39 +0000 (23:57 +0000)
CHANGES
bin/nsupdate/nsupdate.c

diff --git a/CHANGES b/CHANGES
index 12d707410644ed00ea07ce5a84da0f46d3d27604..635c8e44e4e7c8e15f3f50abb01df7ec0e5c6606 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,5 @@
+2153.  [bug]           nsupdate could leak memory. [RT #16691]
+
 2152.  [cleanup]       Use sizeof(buf) instead of fixed number in
                        dighost.c:get_trusted_key(). [RT #16678]
 
index 5491178fabe25c28a13741d8fee0161fc8f9b00d..5e7717057f17a470aa3abd91242a487671f99aee 100644 (file)
@@ -15,7 +15,7 @@
  * PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: nsupdate.c,v 1.146 2006/12/07 05:39:41 marka Exp $ */
+/* $Id: nsupdate.c,v 1.147 2007/02/28 23:57:39 marka Exp $ */
 
 /*! \file */
 
@@ -2416,6 +2416,10 @@ start_update(void) {
                        result = dns_message_firstname(updatemsg, section);
                }
                if (result != ISC_R_SUCCESS) {
+                       dns_message_puttempname(soaquery, &name);
+                       dns_rdataset_disassociate(rdataset);
+                       dns_message_puttemprdataset(soaquery, &rdataset);
+                       dns_message_destroy(&soaquery);
                        done_update();
                        return;
                }