mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-05-21 21:52:20 +00:00
bgpd: do not bounce peer when re-binding to current peer-group
Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
This commit is contained in:
parent
9cdce038c5
commit
ed9fb82638
14
bgpd/bgpd.c
14
bgpd/bgpd.c
@ -2518,11 +2518,17 @@ int peer_group_bind(struct bgp *bgp, union sockunion *su, struct peer *peer,
|
|||||||
|
|
||||||
/* The peer exist, bind it to the peer-group */
|
/* The peer exist, bind it to the peer-group */
|
||||||
if (peer) {
|
if (peer) {
|
||||||
/* When the peer already belongs to peer group, check the
|
/* When the peer already belongs to a peer-group, check the
|
||||||
* consistency. */
|
* consistency. */
|
||||||
if (peer_group_active(peer)
|
if (peer_group_active(peer)) {
|
||||||
&& strcmp(peer->group->name, group->name) != 0)
|
|
||||||
return BGP_ERR_PEER_GROUP_CANT_CHANGE;
|
/* The peer is already bound to the peer-group,
|
||||||
|
* nothing to do */
|
||||||
|
if (strcmp(peer->group->name, group->name) == 0)
|
||||||
|
return 0;
|
||||||
|
else
|
||||||
|
return BGP_ERR_PEER_GROUP_CANT_CHANGE;
|
||||||
|
}
|
||||||
|
|
||||||
/* The peer has not specified a remote-as, inherit it from the
|
/* The peer has not specified a remote-as, inherit it from the
|
||||||
* peer-group */
|
* peer-group */
|
||||||
|
Loading…
Reference in New Issue
Block a user