[frr] [PATCH 10/11] bgpd: avoid looping when unselecting a list of mpath entries

Philippe Guibert philippe.guibert at 6wind.com
Wed Dec 21 09:13:55 EST 2016


sometimes, when electing best route algorithm, a static route
may be injected, thus causing all old multipath entries to be
removed from multipath list. As a loop is removing each mpath
entry from mpath list, it is necessary to update the pointer.

Signed-off-by: Philippe Guibert <philippe.guibert at 6wind.com>
---
 bgpd/bgp_mpath.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/bgpd/bgp_mpath.c b/bgpd/bgp_mpath.c
index f2e6bba11d1a..4ca7bc7d6c80 100644
--- a/bgpd/bgp_mpath.c
+++ b/bgpd/bgp_mpath.c
@@ -584,6 +584,7 @@ bgp_info_mpath_update (struct bgp_node *rn, struct bgp_info *new_best,
                                      nh_buf[0], sizeof (nh_buf[0])),
                           mpath_count);
             }
+          mp_node = mp_next_node;
           cur_mpath = next_mpath;
         }
       else
-- 
2.1.4





More information about the dev mailing list