diff options
author | ume <ume@FreeBSD.org> | 2001-03-23 18:59:31 +0000 |
---|---|---|
committer | ume <ume@FreeBSD.org> | 2001-03-23 18:59:31 +0000 |
commit | aabe84d0cbca8d7eed5bd5b81cb33f80bca39a55 (patch) | |
tree | 700ba2e4a6b16a6e442280ce6bb1cb2946d327c6 /lib/libc/net/inet_network.c | |
parent | af0ef4a0618c8bc04852f5517a94e7bb9cf23a79 (diff) | |
download | FreeBSD-src-aabe84d0cbca8d7eed5bd5b81cb33f80bca39a55.zip FreeBSD-src-aabe84d0cbca8d7eed5bd5b81cb33f80bca39a55.tar.gz |
IPv4 address is not unsigned int. This change introduces in_addr_t.
PR: 9982
Adviced by: des
Reviewed by: -alpha and -net (no objection)
Obtained from: OpenBSD
Diffstat (limited to 'lib/libc/net/inet_network.c')
-rw-r--r-- | lib/libc/net/inet_network.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/libc/net/inet_network.c b/lib/libc/net/inet_network.c index e44257a..7cc30a5 100644 --- a/lib/libc/net/inet_network.c +++ b/lib/libc/net/inet_network.c @@ -47,13 +47,14 @@ static char sccsid[] = "@(#)inet_network.c 8.1 (Berkeley) 6/4/93"; * The library routines call this routine to interpret * network numbers. */ -u_long +in_addr_t inet_network(cp) register const char *cp; { - register u_long val, base, n, i; + register in_addr_t val, base, n; register char c; - u_long parts[4], *pp = parts; + in_addr_t parts[4], *pp = parts; + register int i; again: val = 0; base = 10; |