From ab96c8509736a7ed622916ad2749ff356e520d02 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Mon, 30 Jan 2017 19:08:57 +0200 Subject: [PATCH] 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) --- src/keyboard.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/keyboard.c b/src/keyboard.c index d41603b2e50..0c04d95304c 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -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; -- 2.39.5