summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoranlan_cs <anlan_cs@126.com>2024-12-05 11:56:34 +0800
committeranlan_cs <anlan_cs@126.com>2024-12-05 21:20:05 +0800
commitf536ca30f522dc14882c4e41e51e6f92ff19f2cc (patch)
tree389f1928499fce239edaba5954b1bfb0613da08e
parent34485ee5368af6825ca0f0c886b6ca064d32580d (diff)
zebra: use macro for one check
Signed-off-by: anlan_cs <anlan_cs@126.com>
-rw-r--r--zebra/zebra_rib.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
index b2543ca0e8..574083ae02 100644
--- a/zebra/zebra_rib.c
+++ b/zebra/zebra_rib.c
@@ -4406,9 +4406,7 @@ int rib_add_multipath(afi_t afi, safi_t safi, struct prefix *p,
if (ng) {
nhe.nhg.nexthop = ng->nexthop;
- if (re->type == ZEBRA_ROUTE_CONNECT ||
- re->type == ZEBRA_ROUTE_LOCAL ||
- re->type == ZEBRA_ROUTE_KERNEL)
+ if (RIB_SYSTEM_ROUTE(re))
SET_FLAG(nhe.flags, NEXTHOP_GROUP_INITIAL_DELAY_INSTALL);
} else if (re->nhe_id > 0)
nhe.id = re->nhe_id;