diff options
Diffstat (limited to '')
-rw-r--r-- | bgpd/bgp_route.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index 7365d5321..787aea168 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -3830,6 +3830,12 @@ bool bgp_update_martian_nexthop(struct bgp *bgp, afi_t afi, safi_t safi, (type == ZEBRA_ROUTE_BGP && stype == BGP_ROUTE_STATIC) ? true : false; + /* If `bgp allow-martian-nexthop` is turned on, return next-hop + * as good. + */ + if (bgp->allow_martian) + return false; + /* * Only validated for unicast and multicast currently. * Also valid for EVPN where the nexthop is an IP address. |