[quagga-dev,16311,1/5] zebra: use FIB state for nexthop tracking

Message ID 20161019130235.26602-2-timo.teras@iki.fi
State Under Review
Headers show
Series
  • NHRP implementation
Related show

Commit Message

Timo Teräs Oct. 19, 2016, 1:02 p.m.
The FIB override routes can override ZEBRA_FLAG_SELECTED routes
in FIB. Use the FIB state instead to report correct nexthop when
FIB override routes are present.
---
 zebra/zebra_rnh.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/zebra/zebra_rnh.c b/zebra/zebra_rnh.c
index 7b6d0f8..97d3597 100644
--- a/zebra/zebra_rnh.c
+++ b/zebra/zebra_rnh.c
@@ -223,7 +223,7 @@  zebra_evaluate_rnh_table (vrf_id_t vrfid, int family)
 	    {
 	      if (CHECK_FLAG (rib->status, RIB_ENTRY_REMOVED))
 		continue;
-	      if (CHECK_FLAG (rib->flags, ZEBRA_FLAG_SELECTED))
+	      if (CHECK_FLAG (rib->status, RIB_ENTRY_SELECTED_FIB))
 		{
 		  if (CHECK_FLAG(rnh->flags, ZEBRA_NHT_CONNECTED))
 		    {