]> git.ipfire.org Git - thirdparty/rsync.git/commitdiff
Tweak valid_ipaddr() check.
authorWayne Davison <wayne@opencoder.net>
Mon, 22 Jun 2020 18:17:56 +0000 (11:17 -0700)
committerWayne Davison <wayne@opencoder.net>
Mon, 22 Jun 2020 18:17:56 +0000 (11:17 -0700)
clientname.c

index 1e85c84eebb48813747989884aebab1e95a7f1fa..ef5e4d24912fc41e28185326bd685b238174a5c5 100644 (file)
@@ -481,7 +481,7 @@ static int valid_ipaddr(const char *s)
 
                for (count = 0; count < 8; count++) {
                        if (!*s)
-                               return saw_double_colon && count < 7;
+                               return saw_double_colon;
 
                        if (strchr(s, ':') == NULL && strchr(s, '.') != NULL) {
                                if ((!saw_double_colon && count != 6) || (saw_double_colon && count > 6))