hsmw: Manually handle SIGINT

This commit is contained in:
Sebastian Gniazdowski 2016-10-11 09:07:43 +02:00
parent e8e01e6258
commit 3e4c359bdd

View file

@ -241,6 +241,10 @@ if [ "$__hsmw_hcw_call_count" -eq "1" ]; then
zle -N "$pdown_widget" _hsmw_simulate_widget
zle -N "$pup_widget" _hsmw_simulate_widget
# Trap INT to manually interrupt Zle to work around a bug
setopt localtraps
trap 'zle && zle .send-break' INT
if zle .recursive-edit -K hsmw; then
BUFFER="${__hsmw_hcw_found[__hsmw_hcw_index]}"
CURSOR="${#BUFFER}"