bgpd: peer creation now takes care of the su

At some point in the past the peer creation was not
properly setting the su and the code had the release
and re-add when setting the su.  Since peer_create
got a bit of code to handle the su properly the
need to release then add it back in is negated
so remove the code.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
Donald Sharp 2022-11-29 09:00:39 -05:00
parent 1f98f42443
commit 40f67286f7

View File

@ -554,8 +554,6 @@ static void bgp_accept(struct thread *thread)
peer = peer_create(&su, peer1->conf_if, peer1->bgp, peer1->local_as,
peer1->as, peer1->as_type, NULL);
hash_release(peer->bgp->peerhash, peer);
(void)hash_get(peer->bgp->peerhash, peer, hash_alloc_intern);
peer_xfer_config(peer, peer1);
bgp_peer_gr_flags_update(peer);