]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
1182. [bug] The server could throw an assertion failure when
authorBrian Wellington <source@isc.org>
Mon, 21 Jan 2002 16:26:06 +0000 (16:26 +0000)
committerBrian Wellington <source@isc.org>
Mon, 21 Jan 2002 16:26:06 +0000 (16:26 +0000)
                        constructing a negative response packet.

CHANGES
lib/dns/ncache.c

diff --git a/CHANGES b/CHANGES
index e48116f64df2beba27cda0c7a15f0434c1a9cb7e..afeed962e8c0ec212b98f40a0ba5f123b165a182 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,6 @@
+1182.  [bug]           The server could throw an assertion failure when
+                       constructing a negative response packet.
+
 1181.  [func]          Add the "key-directory" configuration statement,
                        which allows the server to look for online signing
                        keys in alternate directories.
index 083f15c7b72b75e860193924b22fe584ee53d6ba..c641cedeaab5b4540c8f184be60445bf2c2406a6 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: ncache.c,v 1.25 2001/11/30 01:59:13 gson Exp $ */
+/* $Id: ncache.c,v 1.26 2002/01/21 16:26:06 bwelling Exp $ */
 
 #include <config.h>
 
@@ -258,7 +258,7 @@ dns_ncache_towire(dns_rdataset_t *rdataset, dns_compress_t *cctx,
 {
        dns_rdata_t rdata = DNS_RDATA_INIT;
        isc_result_t result;
-       isc_region_t remaining, tremaining;
+       isc_region_t remaining, tavailable;
        isc_buffer_t source, savedbuffer, rdlen;
        dns_name_t name;
        dns_rdatatype_t type;
@@ -324,8 +324,8 @@ dns_ncache_towire(dns_rdataset_t *rdataset, dns_compress_t *cctx,
                         * See if we have space for type, class, ttl, and
                         * rdata length.  Write the type, class, and ttl.
                         */
-                       isc_buffer_remainingregion(target, &tremaining);
-                       if (tremaining.length < 10) {
+                       isc_buffer_availableregion(target, &tavailable);
+                       if (tavailable.length < 10) {
                                result = ISC_R_NOSPACE;
                                goto rollback;
                        }