o Fix strtoul() error conditions check.
PR: kern/108211 Submitted by: Yong Tang MFC after: 2 weeks
This commit is contained in:
parent
35e4f24d23
commit
38ec733c53
@ -173,7 +173,7 @@ inet_aton(cp, addr)
|
||||
|
||||
l = strtoul(c, &endptr, 0);
|
||||
|
||||
if (l == ULONG_MAX || l == 0)
|
||||
if (l == ULONG_MAX || (l == 0 && endptr == c))
|
||||
return (0);
|
||||
|
||||
val = (in_addr_t)l;
|
||||
|
Loading…
Reference in New Issue
Block a user