From 1675ada4f4fda2dfc51c8bd1a4f24ec8513ae473 Mon Sep 17 00:00:00 2001 From: Emeric Brun Date: Thu, 22 Apr 2021 18:13:13 +0200 Subject: [PATCH] BUG/MINOR: peers: remove useless table check if initial resync is finished The old process checked each table resync status even if the resync process is finished. This behavior had no known impact except useless processing and was discovered during debugging on an other issue. This patch could be backported in all supported branches (v >= 1.6) but once again, it has no impact except avoid useless processing. --- src/peers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/peers.c b/src/peers.c index b7ea415..d8f0b74 100644 --- a/src/peers.c +++ b/src/peers.c @@ -2223,7 +2223,7 @@ static inline int peer_send_msgs(struct appctx *appctx, } HA_SPIN_UNLOCK(STK_TABLE_LOCK, &st->table->lock); } - else { + else if (!(peer->flags & PEER_F_TEACH_FINISHED)) { if (!(st->flags & SHTABLE_F_TEACH_STAGE1)) { repl = peer_send_teach_stage1_msgs(appctx, peer, st); if (repl <= 0) -- 1.7.10.4