It's easier to explain with example. Let's assume that there is a 1.1.1.1/32 
route resolved
throught 0.0.0.0/0. In case 0.0.0.0/0 goes away 1.1.1.1/32 should be removed 
from kernel as
inactive. But this will not happen as number of nexthops will be equal to 0.

* zebra/rt_netlink.c modified check to delete routes with 0 nexthops 
---
 zebra/rt_netlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c
index 33fbc08..ff1f1dd 100644
--- a/zebra/rt_netlink.c
+++ b/zebra/rt_netlink.c
@@ -1742,7 +1742,7 @@ netlink_route_multipath (int cmd, struct prefix *p, 
struct rib *rib,
     }
 
   /* If there is no useful nexthop then return. */
-  if (nexthop_num == 0)
+  if (nexthop_num == 0 && cmd != RTM_DELROUTE)
     {
       if (IS_ZEBRA_DEBUG_KERNEL)
         zlog_debug ("netlink_route_multipath(): No useful nexthop.");
-- 
2.1.2.AMZN


_______________________________________________
Quagga-dev mailing list
[email protected]
https://lists.quagga.net/mailman/listinfo/quagga-dev

Reply via email to