From 25739271a01f9bc6c80b624963df53e479e39c19 Mon Sep 17 00:00:00 2001 From: Dmitrii Turlupov Date: Wed, 13 Mar 2024 01:14:11 +0300 Subject: [PATCH] bgpd: fix disable bfd profile for neighbors. Before this patch after command 'no neighbor bfd profile [BFDPROF]' has always been created bfd-config for neighbor. Signed-off-by: Dmitrii Turlupov --- bgpd/bgp_bfd.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bgpd/bgp_bfd.c b/bgpd/bgp_bfd.c index 21864cf1a6..14ff5f2e11 100644 --- a/bgpd/bgp_bfd.c +++ b/bgpd/bgp_bfd.c @@ -597,6 +597,9 @@ DEFUN(no_neighbor_bfd_profile, no_neighbor_bfd_profile_cmd, if (!peer) return CMD_WARNING_CONFIG_FAILED; + if (!peer->bfd_config) + return CMD_SUCCESS; + if (CHECK_FLAG(peer->sflags, PEER_STATUS_GROUP)) bgp_group_configure_bfd(peer); else