version 1.75.2.1, 2006/01/30 13:13:55 |
version 1.76, 2005/09/24 15:52:03 |
Line 494 struct cmsghdr { |
|
Line 494 struct cmsghdr { |
|
(((__caddr_t)(cmsg) + __CMSG_ALIGN((cmsg)->cmsg_len) + \ |
(((__caddr_t)(cmsg) + __CMSG_ALIGN((cmsg)->cmsg_len) + \ |
__CMSG_ALIGN(sizeof(struct cmsghdr)) > \ |
__CMSG_ALIGN(sizeof(struct cmsghdr)) > \ |
(((__caddr_t)(mhdr)->msg_control) + (mhdr)->msg_controllen)) ? \ |
(((__caddr_t)(mhdr)->msg_control) + (mhdr)->msg_controllen)) ? \ |
(struct cmsghdr *)0 : \ |
(struct cmsghdr *)NULL : \ |
(struct cmsghdr *)((__caddr_t)(cmsg) + \ |
(struct cmsghdr *)((__caddr_t)(cmsg) + \ |
__CMSG_ALIGN((cmsg)->cmsg_len))) |
__CMSG_ALIGN((cmsg)->cmsg_len))) |
|
|
Line 505 struct cmsghdr { |
|
Line 505 struct cmsghdr { |
|
#define CMSG_FIRSTHDR(mhdr) \ |
#define CMSG_FIRSTHDR(mhdr) \ |
((mhdr)->msg_controllen >= sizeof(struct cmsghdr) ? \ |
((mhdr)->msg_controllen >= sizeof(struct cmsghdr) ? \ |
(struct cmsghdr *)(mhdr)->msg_control : \ |
(struct cmsghdr *)(mhdr)->msg_control : \ |
(struct cmsghdr *)0) |
(struct cmsghdr *)NULL) |
|
|
#define CMSG_SPACE(l) (__CMSG_ALIGN(sizeof(struct cmsghdr)) + __CMSG_ALIGN(l)) |
#define CMSG_SPACE(l) (__CMSG_ALIGN(sizeof(struct cmsghdr)) + __CMSG_ALIGN(l)) |
#define CMSG_LEN(l) (__CMSG_ALIGN(sizeof(struct cmsghdr)) + (l)) |
#define CMSG_LEN(l) (__CMSG_ALIGN(sizeof(struct cmsghdr)) + (l)) |
Line 524 struct cmsghdr { |
|
Line 524 struct cmsghdr { |
|
#define SHUT_WR 1 /* Disallow further sends. */ |
#define SHUT_WR 1 /* Disallow further sends. */ |
#define SHUT_RDWR 2 /* Disallow further sends/receives. */ |
#define SHUT_RDWR 2 /* Disallow further sends/receives. */ |
|
|
#if defined(_NETBSD_SOURCE) |
|
/* |
|
* 4.3 compat sockaddr, move to compat file later |
|
*/ |
|
struct osockaddr { |
|
__uint16_t sa_family; /* address family */ |
|
char sa_data[14]; /* up to 14 bytes of direct address */ |
|
}; |
|
|
|
/* |
|
* 4.3-compat message header (move to compat file later). |
|
*/ |
|
struct omsghdr { |
|
__caddr_t msg_name; /* optional address */ |
|
int msg_namelen; /* size of address */ |
|
struct iovec *msg_iov; /* scatter/gather array */ |
|
int msg_iovlen; /* # elements in msg_iov */ |
|
__caddr_t msg_accrights; /* access rights sent/received */ |
|
int msg_accrightslen; |
|
}; |
|
#endif |
|
|
|
#include <sys/cdefs.h> |
#include <sys/cdefs.h> |
|
|
__BEGIN_DECLS |
__BEGIN_DECLS |