From 206f5877c0ce4a5c7e0ee1ade1e64b215950c1f8 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Mon, 29 Jun 2026 09:22:50 +0900 Subject: [PATCH] Ignore wait action while already wait-blocked actWait is handled in doActions before the waitBlocked guard in doAction, so a binding containing wait could reset waitBlockedAt, overwrite pendingActions, and spawn extra debounce goroutines while blocked. Ignore it, consistent with how other input is dropped while waiting. --- src/terminal.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/terminal.go b/src/terminal.go index 69243f5c..c0d3939b 100644 --- a/src/terminal.go +++ b/src/terminal.go @@ -6661,6 +6661,10 @@ func (t *Terminal) Loop() error { currentIndex := t.currentIndex() for i, action := range actions { if action.t == actWait { + // Already waiting; ignore so input can't reset the blocked state + if t.waitBlocked { + return true + } // Block if search is in progress or will be triggered if changed || newCommand != nil || t.searchInProgress { t.waitBlocked = true