Commit 7674c51
Cygwin: console: Set ENABLE_PROCESSED_INPUT when disable_master_thread
Currently, ENABLE_PROCESSED_INPUT is set in set_input_mode() if
master_thread_suspended is true. This enables Ctrl-C handling when
cons_master_thread is suspended, since Ctrl-C is normally handled
by cons_master_thread.
However, when disable_master_thread is true, ENABLE_PROCESSED_INPUT
is not set, even though this also disables Ctrl-C handling in
cons_master_thread. Due to this bug, the command
C:\cygwin64\bin\sleep 10 < NUL
in the Command Prompt cannot be terminated with Ctrl-C.
This patch addresses the issue by setting ENABLE_PROCESSED_INPUT
when either disable_master_thread or master_thread_suspended is true.
This bug also affects cases where non-Cygwin Git (Git for Windows)
launches Cygwin SSH. In such cases, SSH also cannot be terminated
with Ctrl-C.
Addresses: git-for-windows/git#5682 (comment)
Fixes: 746c811 ("Cygwin: console: Allow pasting very long text input.")
Reported-by: Johannes Schindelin <[email protected]>
Signed-off-by: Takashi Yano <[email protected]>
(cherry picked from commit 476135a24506dd624eb46b50fd634fcd740008ba)
Cherry-picked-from: 61cc419 (Cygwin: console: Set ENABLE_PROCESSED_INPUT when disable_master_thread, 2025-07-01))
Signed-off-by: Johannes Schindelin <[email protected]>1 parent fe587e1 commit 7674c51
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
831 | 831 | | |
832 | 832 | | |
833 | 833 | | |
834 | | - | |
| 834 | + | |
835 | 835 | | |
836 | 836 | | |
837 | 837 | | |
| |||
0 commit comments