We can abort isis_zebra_route_del_ipv6 if the route in question has
ISIS_ROUTE_FLAG_ZEBRA_SYNCED unset, meaning it's not in the kernel.
Aborting the function if the flag is set prevents us from removing
any routes.

Signed-off-by: Christian Franke <[email protected]>
---
 isisd/isis_zebra.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/isisd/isis_zebra.c b/isisd/isis_zebra.c
index 8a78417..1201627 100644
--- a/isisd/isis_zebra.c
+++ b/isisd/isis_zebra.c
@@ -420,7 +420,7 @@ isis_zebra_route_del_ipv6 (struct prefix *prefix,
   struct listnode *node;
   struct prefix_ipv6 prefix6;
 
-  if (CHECK_FLAG (route_info->flag, ISIS_ROUTE_FLAG_ZEBRA_SYNCED))
+  if (!CHECK_FLAG (route_info->flag, ISIS_ROUTE_FLAG_ZEBRA_SYNCED))
     return;
 
   api.vrf_id = VRF_DEFAULT;
-- 
2.6.1


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

Reply via email to