Author: ume Date: Wed Dec 27 14:50:07 2017 New Revision: 327238 URL: https://svnweb.freebsd.org/changeset/base/327238
Log: MFC r327029: Don't ignore trailing spaces after numerical IP addresses. PR: 224403 Modified: stable/10/lib/libc/net/getaddrinfo.c Directory Properties: stable/10/ (props changed) Changes in other areas also in this revision: Modified: stable/11/lib/libc/net/getaddrinfo.c Directory Properties: stable/11/ (props changed) Modified: stable/10/lib/libc/net/getaddrinfo.c ============================================================================== --- stable/10/lib/libc/net/getaddrinfo.c Wed Dec 27 09:25:45 2017 (r327237) +++ stable/10/lib/libc/net/getaddrinfo.c Wed Dec 27 14:50:07 2017 (r327238) @@ -1243,7 +1243,8 @@ explore_numeric(const struct addrinfo *pai, const char * does not accept. So we need to separate the case for * AF_INET. */ - if (inet_aton(hostname, (struct in_addr *)pton) != 1) + if (inet_aton(hostname, (struct in_addr *)pton) != 1 || + hostname[strspn(hostname, "0123456789.xabcdefXABCDEF")] != '\0') return 0; break; default: _______________________________________________ svn-src-stable-10@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10 To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"