Avoid crashes on C-g in TTY sessions

* src/keyboard.c (handle_interrupt): Don't quit if
waiting_for_input is set, as doing that is "unsafe": it will
abort.  (Bug#25566)
This commit is contained in:
Eli Zaretskii 2017-01-30 19:08:57 +02:00
parent 9c4dfdd1af
commit ab96c85097

View file

@ -10448,7 +10448,7 @@ handle_interrupt (bool in_signal_handler)
/* If executing a function that wants to be interrupted out of
and the user has not deferred quitting by binding `inhibit-quit'
then quit right away. */
if (immediate_quit && NILP (Vinhibit_quit))
if (immediate_quit && NILP (Vinhibit_quit) && !waiting_for_input)
{
struct gl_state_s saved;