summaryrefslogtreecommitdiff
path: root/src/basic/socket-util.h
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-10-27 01:03:03 +0100
committerLennart Poettering <lennart@poettering.net>2015-10-27 13:25:57 +0100
commit8f328d36c9c66efdb40fd19a970523d715078826 (patch)
tree9db8fb9b093f81f078caa7f6a01c4e43359b077a /src/basic/socket-util.h
parentafc5dbf37fd2399d37976388d9dd9ab470ecf446 (diff)
socket-util: move CMSG_FOREACH() from macro.h to socket-util.h
Diffstat (limited to 'src/basic/socket-util.h')
-rw-r--r--src/basic/socket-util.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/basic/socket-util.h b/src/basic/socket-util.h
index 8b5410b391..c60f2556af 100644
--- a/src/basic/socket-util.h
+++ b/src/basic/socket-util.h
@@ -127,3 +127,6 @@ int getpeersec(int fd, char **ret);
int send_one_fd(int transport_fd, int fd, int flags);
int receive_one_fd(int transport_fd, int flags);
+
+#define CMSG_FOREACH(cmsg, mh) \
+ for ((cmsg) = CMSG_FIRSTHDR(mh); (cmsg); (cmsg) = CMSG_NXTHDR((mh), (cmsg)))