]> git.puffer.fish Git - mirror/frr.git/commitdiff
Merge branch 'master' of https://github.com/dwalton76/frr into bgpd-ipv4-plus-label...
authorDaniel Walton <dwalton@cumulusnetworks.com>
Mon, 10 Jul 2017 13:06:19 +0000 (13:06 +0000)
committerDaniel Walton <dwalton@cumulusnetworks.com>
Mon, 10 Jul 2017 13:06:19 +0000 (13:06 +0000)
Conflicts:
bgpd/bgp_route.c
bgpd/bgp_zebra.c

1  2 
bgpd/bgp_vty.c
bgpd/bgp_zebra.c
bgpd/bgpd.c
bgpd/rfapi/rfapi_vty.c
vtysh/vtysh.c
zebra/zebra_mpls.c
zebra/zebra_vty.c

diff --cc bgpd/bgp_vty.c
Simple merge
index 47723f1dc4870a3d20963b45e3d2a8032bf88ad4,b4a723281a3aaa2856403a0ef10ab2bd9cb2a96d..71a4d4317a91aa0d6dbebbb5111387c3ba5b1e73
@@@ -1278,20 -1275,8 +1275,9 @@@ bgp_zebra_announce (struct bgp_node *rn
        struct in_addr *nexthop;
        char buf[2][INET_ADDRSTRLEN];
        int valid_nh_count = 0;
 +      int has_valid_label = 0;
  
        /* resize nexthop buffer size if necessary */
-       if ((oldsize = stream_get_size (bgp_nexthop_buf)) <
-           (sizeof (struct in_addr *) * nhcount))
-         {
-           newsize = sizeof (struct in_addr *) * nhcount;
-           newsize = stream_resize (bgp_nexthop_buf, newsize);
-           if (newsize == oldsize)
-             {
-                 zlog_err ("can't resize nexthop buffer");
-                 return;
-             }
-         }
        stream_reset (bgp_nexthop_buf);
        nexthop = NULL;
  
        struct zapi_ipv6 api;
        int valid_nh_count = 0;
            char buf[2][INET6_ADDRSTRLEN];
 +      int has_valid_label = 0;
  
-       /* resize nexthop buffer size if necessary */
-       if ((oldsize = stream_get_size (bgp_nexthop_buf)) <
-           (sizeof (struct in6_addr *) * nhcount))
-         {
-           newsize = (sizeof (struct in6_addr *) * nhcount);
-           newsize = stream_resize (bgp_nexthop_buf, newsize);
-           if (newsize == oldsize)
-             {
-               zlog_err ("can't resize nexthop buffer");
-               return;
-             }
-         }
        stream_reset (bgp_nexthop_buf);
-       /* resize ifindices buffer size if necessary */
-       if ((oldsize = stream_get_size (bgp_ifindices_buf)) <
-           (sizeof (unsigned int) * nhcount))
-         {
-           newsize = (sizeof (unsigned int) * nhcount);
-           newsize = stream_resize (bgp_ifindices_buf, newsize);
-           if (newsize == oldsize)
-             {
-               zlog_err ("can't resize nexthop buffer");
-               return;
-             }
-         }
        stream_reset (bgp_ifindices_buf);
-       /* For labeled unicast, each nexthop has a label too. Resize label
-        * buffer, if required.
-        */
-       if (safi == SAFI_UNICAST)
-         {
-           if ((oldsize = stream_get_size (bgp_label_buf)) <
-               (sizeof (unsigned int) * nhcount))
-             {
-               newsize = (sizeof (unsigned int) * nhcount);
-               newsize = stream_resize (bgp_label_buf, newsize);
-               if (newsize == oldsize)
-                 {
-                   zlog_err ("can't resize label buffer");
-                   return;
-                 }
-             }
-           stream_reset (bgp_label_buf);
-         }
+       stream_reset (bgp_label_buf);
  
        ifindex = 0;
        nexthop = NULL;
diff --cc bgpd/bgpd.c
Simple merge
Simple merge
diff --cc vtysh/vtysh.c
Simple merge
Simple merge
Simple merge