]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Fixes problems with routing table scans on some platforms.
authorOndrej Zajicek <santiago@crfreenet.org>
Tue, 28 May 2013 08:44:44 +0000 (10:44 +0200)
committerOndrej Zajicek <santiago@crfreenet.org>
Tue, 28 May 2013 08:44:44 +0000 (10:44 +0200)
Negative bit shifts are definitely undefined oprations.

sysdep/linux/netlink.c

index d1b203ef65ea6e483049c8f98ce06a739bfa58ca..1d24ae0ff290be68ff636e002b700caa639eeade 100644 (file)
@@ -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);