From e734c1d08a39e53cae817c6e4cc8aed20dc43b81 Mon Sep 17 00:00:00 2001 From: Ramskyi Roman Date: Sun, 9 Aug 2026 17:28:50 +0300 Subject: [PATCH] Added a check to see if the timer queue is empty so destroying a shardless cluster doesn't cause an assertion failure --- src/dpp/cluster/timer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dpp/cluster/timer.cpp b/src/dpp/cluster/timer.cpp index 37a248474a..31338ba9be 100644 --- a/src/dpp/cluster/timer.cpp +++ b/src/dpp/cluster/timer.cpp @@ -67,7 +67,7 @@ void cluster::tick_timers() { timer_t cur_timer; { std::lock_guard l(timer_guard); - if (next_timer.top().next_tick > now) { + if (next_timer.empty() || next_timer.top().next_tick > now) { /* Nothing to do */ break; }