summaryrefslogtreecommitdiff
path: root/lib/libform
diff options
context:
space:
mode:
authorblymn <blymn@NetBSD.org>2001-02-16 03:28:24 +0000
committerblymn <blymn@NetBSD.org>2001-02-16 03:28:24 +0000
commita6ae537d07d524325247a02bc0153f2dfbaebe1e (patch)
tree05ee8333c794807230a2a3035be94a3d195b5e56 /lib/libform
parent3ebef9c4071ebe877b05c2389ceaa58a99ecce1c (diff)
Handle the "unknown" ipv6 address form (::).
Diffstat (limited to 'lib/libform')
-rw-r--r--lib/libform/type_ipv6.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/libform/type_ipv6.c b/lib/libform/type_ipv6.c
index a5225aa6d50..ce7a1ab88b2 100644
--- a/lib/libform/type_ipv6.c
+++ b/lib/libform/type_ipv6.c
@@ -1,4 +1,4 @@
-/* $NetBSD: type_ipv6.c,v 1.2 2001/02/11 12:15:30 blymn Exp $ */
+/* $NetBSD: type_ipv6.c,v 1.3 2001/02/16 03:28:24 blymn Exp $ */
/*-
* Copyright (c) 1998-1999 Brett Lymn
@@ -150,6 +150,9 @@ ipv6_check_field(FIELD *field, char *args)
goto FAIL;
p++;
+ if (*p == '\0')
+ break;
+
if (!isxdigit(*p))
goto FAIL;
vals[i] = strtoul(p, NULL, 16);