mirror of
https://github.com/junegunn/fzf.git
synced 2026-08-13 12:33:44 +02:00
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.
This commit is contained in:
parent
5b4afa0447
commit
206f5877c0
1 changed files with 4 additions and 0 deletions
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue