]> git.eshelyaron.com Git - emacs.git/commitdiff
Avoid crashes on C-g in TTY sessions
authorEli Zaretskii <eliz@gnu.org>
Mon, 30 Jan 2017 17:08:57 +0000 (19:08 +0200)
committerEli Zaretskii <eliz@gnu.org>
Mon, 30 Jan 2017 17:08:57 +0000 (19:08 +0200)
* 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

index d41603b2e50aee9dbd7d017cdf989651e0e48377..0c04d95304c31456e35ce4592be218f0f4072366 100644 (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;