diff options
author | David Cantrell <dcantrell@redhat.com> | 2006-05-24 23:55:44 +0000 |
---|---|---|
committer | David Cantrell <dcantrell@redhat.com> | 2006-05-24 23:55:44 +0000 |
commit | cb1d032be5d2ab13a14add12a525b12cce36f50e (patch) | |
tree | e16bba3cfd42b22423d343d5e9a1969af69549ef /isys/nl.c | |
parent | 31f35c885de180215e7a380e5479b4494430399a (diff) | |
download | anaconda-cb1d032be5d2ab13a14add12a525b12cce36f50e.tar.gz anaconda-cb1d032be5d2ab13a14add12a525b12cce36f50e.tar.xz anaconda-cb1d032be5d2ab13a14add12a525b12cce36f50e.zip |
* isys/nl.c: Skip Netlink messages with void ARP headers or zero-length
ARP headers.
Diffstat (limited to 'isys/nl.c')
-rw-r--r-- | isys/nl.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -24,6 +24,7 @@ #include <linux/netlink.h> #include <linux/rtnetlink.h> #include <arpa/inet.h> +#include <net/if_arp.h> #include <glib.h> @@ -283,6 +284,12 @@ int netlink_init_interfaces_list(void) { rta = IFLA_RTA(ifi); len = IFLA_PAYLOAD(nlh); + /* void and none are bad */ + if (ifi->ifi_type == ARPHRD_VOID || ifi->ifi_type == ARPHRD_NONE) { + nlh = NLMSG_NEXT(nlh, ret); + continue; + } + while (RTA_OK(rta, len)) { if (rta->rta_type <= len) tb[rta->rta_type] = rta; |