a '.' is allowed in IPv6 addresses, see RFC2732 - gopher-validator - Gopher val… | |
git clone git://git.codemadness.org/gopher-validator | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit ea7e95bed480772aa6a83526d0a8f7d34dd08656 | |
parent e4a622665300d0c8c5ce1a4fa6608f6733f3c191 | |
Author: Hiltjo Posthuma <[email protected]> | |
Date: Sun, 11 Aug 2019 11:34:13 +0200 | |
a '.' is allowed in IPv6 addresses, see RFC2732 | |
for example "::FFFF:129.144.52.38" is a valid address. | |
Diffstat: | |
M gopher-validator.c | 2 +- | |
1 file changed, 1 insertion(+), 1 deletion(-) | |
--- | |
diff --git a/gopher-validator.c b/gopher-validator.c | |
@@ -143,7 +143,7 @@ isvalidserver(const char *s) | |
colons++; | |
else if (*s == ']') | |
break; | |
- else if (isxdigit((unsigned char)*s)) | |
+ else if (isxdigit((unsigned char)*s) || *s == '.') | |
; | |
else | |
return 0; |