]> git.puffer.fish Git - mirror/frr.git/commitdiff
Merge pull request #899 from donaldsharp/ETH_ALEN
authorDavid Lamparter <equinox@diac24.net>
Sat, 5 Aug 2017 03:19:01 +0000 (05:19 +0200)
committerGitHub <noreply@github.com>
Sat, 5 Aug 2017 03:19:01 +0000 (05:19 +0200)
Fix Crash and Convert to ETH_ALEN

1  2 
zebra/rt_netlink.c

index 887ea4794d91fb4c51bf5a1d6b62cf9bdbfeabc9,cf78a197ce678e6ae159e050efe2502cce25dfa6..192fffd29c9469eb0adfef8e9c55d8a50e3f8aca
@@@ -1704,9 -1704,9 +1704,9 @@@ static int netlink_macfdb_change(struc
                return 0;
        }
  
-       if (RTA_PAYLOAD(tb[NDA_LLADDR]) != ETHER_ADDR_LEN) {
+       if (RTA_PAYLOAD(tb[NDA_LLADDR]) != ETH_ALEN) {
                zlog_warn(
 -                      "%s family %s IF %s(%u) brIF %u - LLADDR is not MAC, len %ld",
 +                      "%s family %s IF %s(%u) brIF %u - LLADDR is not MAC, len %lu",
                        nl_msg_type_to_str(h->nlmsg_type),
                        nl_family_to_str(ndm->ndm_family), ifp->name,
                        ndm->ndm_ifindex, zif->brslave_info.bridge_ifindex,
@@@ -2033,9 -2033,9 +2033,9 @@@ static int netlink_ipneigh_change(struc
  
        if (h->nlmsg_type == RTM_NEWNEIGH) {
                if (tb[NDA_LLADDR]) {
-                       if (RTA_PAYLOAD(tb[NDA_LLADDR]) != ETHER_ADDR_LEN) {
+                       if (RTA_PAYLOAD(tb[NDA_LLADDR]) != ETH_ALEN) {
                                zlog_warn(
 -                                      "%s family %s IF %s(%u) - LLADDR is not MAC, len %ld",
 +                                      "%s family %s IF %s(%u) - LLADDR is not MAC, len %lu",
                                        nl_msg_type_to_str(h->nlmsg_type),
                                        nl_family_to_str(ndm->ndm_family),
                                        ifp->name, ndm->ndm_ifindex,