]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
pullup:
authorMark Andrews <marka@isc.org>
Sat, 13 Oct 2001 03:52:13 +0000 (03:52 +0000)
committerMark Andrews <marka@isc.org>
Sat, 13 Oct 2001 03:52:13 +0000 (03:52 +0000)
1050.  [bug]           Log messages reporting malformed IP addresses in
                       address lists such as that of the forwarders option
                       failed to include the correct error code, file
                       name, and line number. [RT #1890]

CHANGES
lib/isccfg/parser.c

diff --git a/CHANGES b/CHANGES
index 4bda22bdc55a45f9f9a288d69ca31627db424a86..c6b5f9c5633c42685a6537831bf2611811d17475 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,9 @@
 1048.  [bug]           Servers built with -DISC_MEM_USE_INTERNAL_MALLOC=1
+1050.  [bug]           Log messages reporting malformed IP addresses in
+                       address lists such as that of the forwarders option
+                       failed to include the correct error code, file
+                       name, and line number. [RT #1890]
+
                        didn't work.
 
 1047.  [bug]           named was incorrectly refusing all requests signed
index bc7b277fd4fdb20b5109b31b06a3b7947dd73c43..733ef41d01a6072b1b701bba2fabea93d654823a 100644 (file)
@@ -15,7 +15,7 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-/* $Id: parser.c,v 1.70.2.2 2001/09/06 23:06:43 marka Exp $ */
+/* $Id: parser.c,v 1.70.2.3 2001/10/13 03:52:13 marka Exp $ */
 
 #include <config.h>
 
@@ -2780,14 +2780,16 @@ token_addr(cfg_parser_t *pctx, unsigned int flags, isc_netaddr_t *na) {
                        }
                }
        }
-       return (ISC_R_NOTFOUND); /* XXX */
+       return (ISC_R_UNEXPECTEDTOKEN);
 }
 
 static isc_result_t
 get_addr(cfg_parser_t *pctx, unsigned int flags, isc_netaddr_t *na) {
        isc_result_t result;
        CHECK(cfg_gettoken(pctx, 0));
-       CHECK(token_addr(pctx, flags, na));
+       result = token_addr(pctx, flags, na);
+       if (result == ISC_R_UNEXPECTEDTOKEN)
+               parser_error(pctx, LOG_NEAR, "expected IP address");
  cleanup:
        return (result);
 }
@@ -2943,7 +2945,6 @@ parse_netaddr(cfg_parser_t *pctx, const cfg_type_t *type, cfg_obj_t **ret) {
        *ret = obj;
        return (ISC_R_SUCCESS);
  cleanup:
-       parser_error(pctx, LOG_NEAR, "expected IP address");
        CLEANUP_OBJ(obj);
        return (result);
 }