diff options
Diffstat (limited to 'cpukit/libnetworking/sys/socket.h')
-rw-r--r-- | cpukit/libnetworking/sys/socket.h | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/cpukit/libnetworking/sys/socket.h b/cpukit/libnetworking/sys/socket.h index e52f975577..88ac33d9c7 100644 --- a/cpukit/libnetworking/sys/socket.h +++ b/cpukit/libnetworking/sys/socket.h @@ -39,10 +39,19 @@ #include <sys/cdefs.h> -#if defined(__rtems__) -/* RTEMS doesn't have FreeBSD's sys/_types.h machinery. */ -typedef int socklen_t; -typedef unsigned char sa_family_t; +#ifndef _IN_PORT_T_DECLARED +typedef unsigned short in_port_t; +#define _IN_PORT_T_DECLARED +#endif + +#ifndef _SA_FAMILY_T_DECLARED +typedef unsigned char sa_family_t; +#define _SA_FAMILY_T_DECLARED +#endif + +#ifndef _SOCKLEN_T_DECLARED +typedef int socklen_t; +#define _SOCKLEN_T_DECLARED #endif /* |