diff options
author | Tom Gundersen <teg@jklm.no> | 2014-02-15 00:06:09 +0100 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2014-02-15 12:14:45 +0100 |
commit | 818dc5e72af8a3eb772997188e2bd8ea616de844 (patch) | |
tree | 30719808a06b1a606ad5b61c0ce511b78d722b1c /src/libsystemd/sd-rtnl | |
parent | 0bfedf143c72005cb540ddcaf9a8630844e381f8 (diff) |
sd-rtnl: always include linux/rtnetlink.h
Diffstat (limited to 'src/libsystemd/sd-rtnl')
-rw-r--r-- | src/libsystemd/sd-rtnl/rtnl-message.c | 3 | ||||
-rw-r--r-- | src/libsystemd/sd-rtnl/rtnl-util.c | 1 | ||||
-rw-r--r-- | src/libsystemd/sd-rtnl/test-rtnl.c | 1 |
3 files changed, 2 insertions, 3 deletions
diff --git a/src/libsystemd/sd-rtnl/rtnl-message.c b/src/libsystemd/sd-rtnl/rtnl-message.c index 096a32236c..15e3247aca 100644 --- a/src/libsystemd/sd-rtnl/rtnl-message.c +++ b/src/libsystemd/sd-rtnl/rtnl-message.c @@ -19,7 +19,6 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>. ***/ -#include <linux/rtnetlink.h> #include <netinet/in.h> #include <netinet/ether.h> #include <stdbool.h> @@ -232,6 +231,8 @@ int sd_rtnl_message_new_addr(uint16_t nlmsg_type, int index, unsigned char famil (*ret)->hdr->nlmsg_len = NLMSG_LENGTH(sizeof(struct ifaddrmsg)); (*ret)->hdr->nlmsg_type = nlmsg_type; + if (nlmsg_type == RTM_GETADDR && family == AF_INET) + (*ret)->hdr->nlmsg_flags |= NLM_F_DUMP; ifa = NLMSG_DATA((*ret)->hdr); diff --git a/src/libsystemd/sd-rtnl/rtnl-util.c b/src/libsystemd/sd-rtnl/rtnl-util.c index caa21d60f5..6545ad0c5b 100644 --- a/src/libsystemd/sd-rtnl/rtnl-util.c +++ b/src/libsystemd/sd-rtnl/rtnl-util.c @@ -19,7 +19,6 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>. ***/ -#include <linux/rtnetlink.h> #include <netinet/ether.h> #include "sd-rtnl.h" diff --git a/src/libsystemd/sd-rtnl/test-rtnl.c b/src/libsystemd/sd-rtnl/test-rtnl.c index 53efed561a..21e12f65e3 100644 --- a/src/libsystemd/sd-rtnl/test-rtnl.c +++ b/src/libsystemd/sd-rtnl/test-rtnl.c @@ -19,7 +19,6 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>. ***/ -#include <linux/rtnetlink.h> #include <netinet/ether.h> #include "util.h" |