diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2015-01-18 04:52:04 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2015-01-18 04:52:04 +0000 |
commit | 2fe134007d1bf961edea5e74e5a3075a795a6a55 (patch) | |
tree | 981481a33f5991b2f273000aa0bbafe13a42c85d /sys | |
parent | 8412d0d6811045a3823f2c6ffaf86b66ef45b973 (diff) |
Per POSIX, <sys/socket.h> needs to expose struct iovec, and may do so
by pulling in <sys/uio.h>, so do so. Remove some stuff that we can trust
<sys/uio.h> to also provide, like cdefs.h, _types.h, and exposing size_t
and ssize_t
pointed out by naddy@
ok deraadt@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/sys/socket.h | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/sys/sys/socket.h b/sys/sys/socket.h index fa5d5bb527a..514adb8f3bb 100644 --- a/sys/sys/socket.h +++ b/sys/sys/socket.h @@ -1,4 +1,4 @@ -/* $OpenBSD: socket.h,v 1.85 2014/08/31 02:27:37 guenther Exp $ */ +/* $OpenBSD: socket.h,v 1.86 2015/01/18 04:52:03 guenther Exp $ */ /* $NetBSD: socket.h,v 1.14 1996/02/09 18:25:36 christos Exp $ */ /* @@ -35,12 +35,11 @@ #ifndef _SYS_SOCKET_H_ #define _SYS_SOCKET_H_ -#include <sys/cdefs.h> +/* get the definitions for struct iovec, size_t, ssize_t, and <sys/cdefs.h> */ +#include <sys/uio.h> #if __BSD_VISIBLE #include <sys/types.h> /* for off_t, uid_t, and gid_t */ -#else -#include <sys/_types.h> #endif #ifndef _SOCKLEN_T_DEFINED_ @@ -53,16 +52,6 @@ typedef __socklen_t socklen_t; /* length type for network syscalls */ typedef __sa_family_t sa_family_t; /* sockaddr address family type */ #endif -#ifndef _SIZE_T_DEFINED_ -#define _SIZE_T_DEFINED_ -typedef __size_t size_t; -#endif - -#ifndef _SSIZE_T_DEFINED_ -#define _SSIZE_T_DEFINED_ -typedef __ssize_t ssize_t; -#endif - /* * Definitions related to sockets: types, address families, options. |