summaryrefslogtreecommitdiff
path: root/src/libsystemd-network/sd-dhcp-server.c
diff options
context:
space:
mode:
authorDaniel Mack <github@zonque.org>2015-06-10 20:06:43 +0200
committerDaniel Mack <github@zonque.org>2015-06-10 20:06:43 +0200
commita8467435a0c4962cab89574f65e7318ef389351f (patch)
treecea7229033673996d2d492ee29b171ef96096d6e /src/libsystemd-network/sd-dhcp-server.c
parent1f8cc1284c586b06ddf2ba5e5d8c9f13f987a1c5 (diff)
parent2a1288ff89322a2f49c79f6d1832c8164c14a05c (diff)
Merge pull request #147 from poettering/cmsg
util: introduce CMSG_FOREACH() macro and make use of it everywhere
Diffstat (limited to 'src/libsystemd-network/sd-dhcp-server.c')
-rw-r--r--src/libsystemd-network/sd-dhcp-server.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsystemd-network/sd-dhcp-server.c b/src/libsystemd-network/sd-dhcp-server.c
index a0a2320efa..cc5e032344 100644
--- a/src/libsystemd-network/sd-dhcp-server.c
+++ b/src/libsystemd-network/sd-dhcp-server.c
@@ -902,7 +902,7 @@ static int server_receive_message(sd_event_source *s, int fd,
else if ((size_t)len < sizeof(DHCPMessage))
return 0;
- for (cmsg = CMSG_FIRSTHDR(&msg); cmsg; cmsg = CMSG_NXTHDR(&msg, cmsg)) {
+ CMSG_FOREACH(cmsg, &msg) {
if (cmsg->cmsg_level == IPPROTO_IP &&
cmsg->cmsg_type == IP_PKTINFO &&
cmsg->cmsg_len == CMSG_LEN(sizeof(struct in_pktinfo))) {