commit | 68bfb6190e19898adc0e420b6346cf4778705e60 | [log] [tgz] |
---|---|---|
author | Lou Berger <lberger@labn.net> | Thu Oct 06 09:59:32 2016 -0400 |
committer | Paul Jakma <paul.jakma@hpe.com> | Fri Oct 07 10:53:15 2016 +0100 |
tree | fbccbc160a94c245abee2696fef805da7f620b4b | |
parent | 743dd42b3f5d4bc5f9a86b91364c67217f42c6d1 [diff] [blame] |
bgp: ignore NHT when bgpd has never connected zebra
diff --git a/bgpd/bgp_nht.c b/bgpd/bgp_nht.c index 50f14ce..0cfcadd 100644 --- a/bgpd/bgp_nht.c +++ b/bgpd/bgp_nht.c
@@ -62,7 +62,8 @@ if (connected && !(CHECK_FLAG(bnc->flags, BGP_NEXTHOP_CONNECTED))) return 0; - return (CHECK_FLAG(bnc->flags, BGP_NEXTHOP_VALID)); + return (bgp_zebra_num_connects() == 0 || + CHECK_FLAG(bnc->flags, BGP_NEXTHOP_VALID)); } static void