According to POSIX sys/socket.h must define CMSG_NXTHDR but most not
define NULL. This means we cannot use NULL in the definition of CMSG_NXTHDR. So replace NULL with 0. PR: kern/60309 Submitted by: Jeff King <peff-freebsd@peff.net>
This commit is contained in:
parent
f7175fc0c6
commit
03c1f3ab46
@ -444,7 +444,7 @@ struct cmsgcred {
|
||||
(((char *)(cmsg) + _ALIGN((cmsg)->cmsg_len) + \
|
||||
_ALIGN(sizeof(struct cmsghdr)) > \
|
||||
(char *)(mhdr)->msg_control + (mhdr)->msg_controllen) ? \
|
||||
(struct cmsghdr *)NULL : \
|
||||
(struct cmsghdr *)0 : \
|
||||
(struct cmsghdr *)((char *)(cmsg) + _ALIGN((cmsg)->cmsg_len)))
|
||||
|
||||
#define CMSG_FIRSTHDR(mhdr) ((struct cmsghdr *)(mhdr)->msg_control)
|
||||
|
Loading…
Reference in New Issue
Block a user