diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2013-05-28 10:44:44 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2013-05-28 10:44:44 +0200 |
commit | 9810d055628877232f811d684567e203381e10dc (patch) | |
tree | 968f3edb87cd376434c1174fc079f9cb6ae2a7eb /sysdep | |
parent | 9c99d753fd672bd9839715ee325ef01cca993dbf (diff) |
Fixes problems with routing table scans on some platforms.
Negative bit shifts are definitely undefined oprations.
Diffstat (limited to 'sysdep')
-rw-r--r-- | sysdep/linux/netlink.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sysdep/linux/netlink.c b/sysdep/linux/netlink.c index d1b203ef..1d24ae0f 100644 --- a/sysdep/linux/netlink.c +++ b/sysdep/linux/netlink.c @@ -843,9 +843,11 @@ nl_parse_route(struct nlmsghdr *h, int scan) memcpy(&ra.gw, RTA_DATA(a[RTA_GATEWAY]), sizeof(ra.gw)); ipa_ntoh(ra.gw); +#ifdef IPV6 /* Silently skip strange 6to4 routes */ if (ipa_in_net(ra.gw, IPA_NONE, 96)) return; +#endif ng = neigh_find2(&p->p, &ra.gw, ra.iface, (i->rtm_flags & RTNH_F_ONLINK) ? NEF_ONLINK : 0); |