From b9910027dd0cf95c5e683b596045e215cb76ba18 Mon Sep 17 00:00:00 2001 From: mike Date: Sun, 10 Mar 2002 06:42:27 +0000 Subject: o Add INET_ADDRSTRLEN and INET6_ADDRSTRLEN defines to for POSIX.1-2001 conformance. o Add magic to and to prevent redefining INET_ADDRSTRLEN and INET6_ADDRSTRLEN. o Add a note about missing typedefs in . --- include/arpa/inet.h | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'include/arpa') diff --git a/include/arpa/inet.h b/include/arpa/inet.h index 9c9554e..42daebf 100644 --- a/include/arpa/inet.h +++ b/include/arpa/inet.h @@ -64,6 +64,14 @@ /* Required for byteorder(3) functions. */ #include +#ifndef INET_ADDRSTRLEN +#define INET_ADDRSTRLEN 16 +#endif + +#ifndef INET6_ADDRSTRLEN +#define INET6_ADDRSTRLEN 46 +#endif + #ifndef _IN_ADDR_T_DECLARED_ typedef __uint32_t in_addr_t; #define _IN_ADDR_T_DECLARED_ @@ -82,8 +90,8 @@ typedef _BSD_SIZE_T_ size_t; #endif /* !_POSIX_SOURCE */ /* - * XXX socklen_t is used by a POSIX.1-200x interface, but not required by - * POSIX.1-200x. + * XXX socklen_t is used by a POSIX.1-2001 interface, but not required by + * POSIX.1-2001. */ #ifdef _BSD_SOCKLEN_T_ typedef _BSD_SOCKLEN_T_ socklen_t; @@ -97,6 +105,10 @@ struct in_addr { #define _STRUCT_IN_ADDR_DECLARED #endif +/* + * XXX missing typedefs for uint16_t and uint32_t. + */ + /* XXX all new diversions!! argh!! */ #ifndef _POSIX_SOURCE #define inet_addr __inet_addr -- cgit v1.1