summaryrefslogtreecommitdiff
path: root/bgpd/bgp_fsm.c
diff options
context:
space:
mode:
authorDonatas Abraitis <donatas@opensourcerouting.org>2025-03-25 09:38:09 +0200
committerGitHub <noreply@github.com>2025-03-25 09:38:09 +0200
commit45af7ea2179b821ab82570c9aec631602654d046 (patch)
tree46a8689556bb982f740e97bebde52302c54d55d7 /bgpd/bgp_fsm.c
parent0a405f477d92c98894bfd9d9d1d0889998069def (diff)
parent9a26a56c5188fd1c95e244932bc17f97b9051935 (diff)
Merge pull request #18483 from donaldsharp/holdtime_mistake
bgpd: Fix holdtime not working properly when busy
Diffstat (limited to 'bgpd/bgp_fsm.c')
-rw-r--r--bgpd/bgp_fsm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/bgpd/bgp_fsm.c b/bgpd/bgp_fsm.c
index 6eecb4770d..478f8c9136 100644
--- a/bgpd/bgp_fsm.c
+++ b/bgpd/bgp_fsm.c
@@ -529,9 +529,11 @@ static void bgp_holdtime_timer(struct event *thread)
frr_with_mutex (&connection->io_mtx) {
inq_count = atomic_load_explicit(&connection->ibuf->count, memory_order_relaxed);
}
- if (inq_count)
+ if (inq_count) {
BGP_TIMER_ON(connection->t_holdtime, bgp_holdtime_timer,
peer->v_holdtime);
+ return;
+ }
EVENT_VAL(thread) = Hold_Timer_expired;
bgp_event(thread); /* bgp_event unlocks peer */