diff options
| author | Donald Sharp <sharpd@nvidia.com> | 2025-03-28 14:54:37 -0400 |
|---|---|---|
| committer | Donald Sharp <sharpd@nvidia.com> | 2025-03-30 14:02:16 -0400 |
| commit | 06480c0c81471d4e00aee669f78e426a083cb759 (patch) | |
| tree | eb24250336bb319ab7c81221dab92b1522e9a829 /bgpd/bgp_fsm.c | |
| parent | 1ef4f190093f62764be0b09c800ddae8a92ced98 (diff) | |
bgpd: When shutting down do not clear self peers
Commit: e0ae285eb8beeef7b43bdadc073d8ae346eaeb6c
Modified the fsm state machine to attempt to not
clear routes on a peer that was not established.
The peer should be not a peer self. We do not want
to ever clear the peer self.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'bgpd/bgp_fsm.c')
| -rw-r--r-- | bgpd/bgp_fsm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bgpd/bgp_fsm.c b/bgpd/bgp_fsm.c index 478f8c9136..940d93a8df 100644 --- a/bgpd/bgp_fsm.c +++ b/bgpd/bgp_fsm.c @@ -1260,7 +1260,7 @@ void bgp_fsm_change_status(struct peer_connection *connection, /* Transition into Clearing or Deleted must /always/ clear all routes.. * (and must do so before actually changing into Deleted.. */ - if (status >= Clearing && (peer->established || peer == bgp->peer_self)) { + if (status >= Clearing && (peer->established || peer != bgp->peer_self)) { bgp_clear_route_all(peer); /* If no route was queued for the clear-node processing, |
