o Backout rev. 1.16, see 1.3 commit log for more info.

Requested by:	bde

o Remove unneeded sys/types.h and netinet/in.h from the synopsis and
the example.
o We do have struct in_addr in arpa/inet.h, so no need for netinet/in.h.
o Mention where AF_* constants defined are.

Educated by:	bde
This commit is contained in:
Maxim Konovalov 2004-10-09 17:13:58 +00:00
parent cf2942b67c
commit e2494b93fc

View File

@ -39,9 +39,6 @@
.Sh LIBRARY
.Lb libc
.Sh SYNOPSIS
.In sys/types.h
.In sys/socket.h
.In netinet/in.h
.In arpa/inet.h
.Ft "char *"
.Fn addr2ascii "int af" "const void *addrp" "int len" "char *buf"
@ -112,7 +109,7 @@ addresses in the specified family:
.It Dv AF_INET
.Li struct in_addr
(in
.In netinet/in.h )
.In arpa/inet.h )
.It Dv AF_LINK
.Li struct sockaddr_dl
(in
@ -122,6 +119,9 @@ addresses in the specified family:
.\" (in
.\" .In netinet6/in6.h )
.El
.Pp
.Dv AF_INET and AF_LINK constants are defined in
.In sys/socket.h
.Sh RETURN VALUES
The
.Fn addr2ascii
@ -141,9 +141,7 @@ and
.Fn inet_aton
could be implemented thusly:
.Bd -literal -offset indent
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
char *