git.samba.org
/
kai
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5e70d80
)
Provide a compatible declaration of CMSG_ALIGN
author
Jakub Hrozek
<jakub.hrozek@gmail.com>
Thu, 2 Oct 2014 05:05:35 +0000
(07:05 +0200)
committer
Andreas Schneider
<asn@cryptomilk.org>
Thu, 2 Oct 2014 07:35:10 +0000
(09:35 +0200)
Some platforms (like OSX) do support some of the CMGS macros, but don't
have a CMSG_ALIGN macro of their own.
Signed-off-by: Jakub Hrozek <jakub.hrozek@gmail.com>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
lib/socket_wrapper/socket_wrapper.c
patch
|
blob
|
history
diff --git
a/lib/socket_wrapper/socket_wrapper.c
b/lib/socket_wrapper/socket_wrapper.c
index 903eec21537429fc69ea4979094888cf71c244a0..930ab58cc5e6cc7e9d86f311d27bdbd2ac808f12 100644
(file)
--- a/
lib/socket_wrapper/socket_wrapper.c
+++ b/
lib/socket_wrapper/socket_wrapper.c
@@
-3336,7
+3336,7
@@
int ioctl(int s, unsigned long int r, ...)
# ifdef _ALIGN /* BSD */
#define CMSG_ALIGN _ALIGN
# else
-#
error NO_CMSG_ALIGN
+#
define CMSG_ALIGN(len) (((len) + sizeof(size_t) - 1) & ~(sizeof(size_t) - 1))
# endif /* _ALIGN */
#endif /* CMSG_ALIGN */