]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
919. [bug] rndc would segfault when rndc.conf was missing the
authorBrian Wellington <source@isc.org>
Mon, 2 Jul 2001 17:55:55 +0000 (17:55 +0000)
committerBrian Wellington <source@isc.org>
Mon, 2 Jul 2001 17:55:55 +0000 (17:55 +0000)
closing brace. [RT #1461]

CHANGES
lib/dns/config/confndc.c

diff --git a/CHANGES b/CHANGES
index 66996dccf6218bff7eb7f92dcbc59b2a8898feff..7b1f918108da60b75fa3a8576d3c500f0ba319f2 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,7 @@
 
+ 919.  [bug]           rndc would segfault when rndc.conf was missing the
+                       closing brace. [RT #1461]
+
        --- 9.1.3rc3 released ---
 
  911.  [bug]           Fail gracefully with multiple hint zones. [RT #1433]
index e566ca363386ddcf50a7a3ebce306727eca57574..a7ed2e365c9d2cbd1e052d221c35b2d81f13c111 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: confndc.c,v 1.25.4.3 2001/06/28 00:44:45 gson Exp $ */
+/* $Id: confndc.c,v 1.25.4.4 2001/07/02 17:55:55 bwelling Exp $ */
 
 /*
 **     options {
@@ -1177,6 +1177,11 @@ parse_keystmt(ndcpcontext *pctx, dns_c_kdeflist_t *keys) {
        while (pctx->currtok != L_RBRACE) {
                isc_uint32_t field = pctx->currtok;
 
+               if (field == L_END_INPUT) {
+                       parser_error(pctx, ISC_TRUE,
+                                    "unexpected end of input");
+                       return (ISC_R_FAILURE);
+               }
                if (!eat(pctx, field)) {
                        result = ISC_R_FAILURE;
                        goto done;