summaryrefslogtreecommitdiff
path: root/src/keyboard.c
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2019-03-01 12:19:03 +0200
committerEli Zaretskii <eliz@gnu.org>2019-03-01 12:19:03 +0200
commited087faa9b1f042e0c47c712e737ef75e90c4f8d (patch)
treed5c7aa7a29c03521a955084251601045dfcaa52d /src/keyboard.c
parent4b63c21f08679c423200132646d48ffb5f97247a (diff)
downloademacs-ed087faa9b1f042e0c47c712e737ef75e90c4f8d.tar.gz
emacs-ed087faa9b1f042e0c47c712e737ef75e90c4f8d.tar.bz2
emacs-ed087faa9b1f042e0c47c712e737ef75e90c4f8d.zip
Don't signal Quit from 'while-no-input' on TTY frames
* src/keyboard.c (read_char): Don't inject quit-char after longjmp if while-no-input is in effect. (Bug#34535)
Diffstat (limited to 'src/keyboard.c')
-rw-r--r--src/keyboard.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/keyboard.c b/src/keyboard.c
index 3af487cf070..c2d8b860e4e 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -2551,7 +2551,10 @@ read_char (int commandflag, Lisp_Object map,
restore_getcjmp (save_jump);
pthread_sigmask (SIG_SETMASK, &empty_mask, 0);
unbind_to (jmpcount, Qnil);
- XSETINT (c, quit_char);
+ /* If we are in while-no-input, don't trigger C-g, as that will
+ quit instead of letting while-no-input do its thing. */
+ if (!EQ (Vquit_flag, Vthrow_on_input))
+ XSETINT (c, quit_char);
internal_last_event_frame = selected_frame;
Vlast_event_frame = internal_last_event_frame;
/* If we report the quit char as an event,