|
@ -1,4 +1,4 @@ |
|
|
/* $OpenBSD: inet.h,v 1.18 2015/09/14 08:16:14 guenther Exp $ */ |
|
|
|
|
|
|
|
|
/* $OpenBSD: inet.h,v 1.19 2015/09/14 08:24:37 guenther Exp $ */ |
|
|
|
|
|
|
|
|
/* |
|
|
/* |
|
|
* ++Copyright++ 1983, 1993 |
|
|
* ++Copyright++ 1983, 1993 |
|
@ -61,9 +61,9 @@ |
|
|
|
|
|
|
|
|
/* External definitions for functions in inet(3) */ |
|
|
/* External definitions for functions in inet(3) */ |
|
|
|
|
|
|
|
|
#include <sys/cdefs.h> |
|
|
|
|
|
#include <sys/_endian.h> |
|
|
|
|
|
|
|
|
#include <sys/types.h> |
|
|
|
|
|
|
|
|
|
|
|
/* <sys/_endian.h> is pulled in by <sys/types.h> */ |
|
|
#ifndef htons |
|
|
#ifndef htons |
|
|
#define htons(x) __htobe16(x) |
|
|
#define htons(x) __htobe16(x) |
|
|
#define htonl(x) __htobe32(x) |
|
|
#define htonl(x) __htobe32(x) |
|
@ -76,12 +76,6 @@ |
|
|
typedef __socklen_t socklen_t; /* length type for network syscalls */ |
|
|
typedef __socklen_t socklen_t; /* length type for network syscalls */ |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
#ifndef _IN_TYPES_DEFINED_ |
|
|
|
|
|
#define _IN_TYPES_DEFINED_ |
|
|
|
|
|
typedef __in_addr_t in_addr_t; /* base type for internet address */ |
|
|
|
|
|
typedef __in_port_t in_port_t; /* IP port type */ |
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
/* |
|
|
/* |
|
|
* Buffer lengths for strings containing printable IP addresses |
|
|
* Buffer lengths for strings containing printable IP addresses |
|
|
*/ |
|
|
*/ |
|
@ -103,15 +97,6 @@ struct in_addr { |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#if __BSD_VISIBLE |
|
|
|
|
|
/* need this for the non-standard stuff */ |
|
|
|
|
|
#ifndef _SIZE_T_DEFINED_ |
|
|
|
|
|
#define _SIZE_T_DEFINED_ |
|
|
|
|
|
typedef __size_t size_t; |
|
|
|
|
|
#endif |
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
__BEGIN_DECLS |
|
|
__BEGIN_DECLS |
|
|
in_addr_t inet_addr(const char *); |
|
|
in_addr_t inet_addr(const char *); |
|
|
char *inet_ntoa(struct in_addr); |
|
|
char *inet_ntoa(struct in_addr); |
|
|