changeset 53658:c6460069583e

(QUIT) [SYNC_INPUT]: Check interrupt_input_pending as well.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Wed, 21 Jan 2004 05:24:01 +0000
parents 4d786e2695ba
children 291acfb4bf40
files src/lisp.h
diffstat 1 files changed, 19 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lisp.h	Wed Jan 21 05:15:12 2004 +0000
+++ b/src/lisp.h	Wed Jan 21 05:24:01 2004 +0000
@@ -1726,6 +1726,22 @@
    This is a good thing to do around a loop that has no side effects
    and (in particular) cannot call arbitrary Lisp code.  */
 
+#ifdef SYNC_INPUT
+extern void handle_async_input P_ ((void));
+extern int interrupt_input_pending;
+#define QUIT						\
+  do {							\
+    if (!NILP (Vquit_flag) && NILP (Vinhibit_quit))	\
+      {							\
+	Vquit_flag = Qnil;				\
+	Fsignal (Qquit, Qnil);				\
+      }							\
+    else if (interrupt_input_pending)			\
+      handle_async_input ();				\
+  } while (0)
+
+#else  /* not SYNC_INPUT */
+
 #define QUIT						\
   do {							\
     if (!NILP (Vquit_flag) && NILP (Vinhibit_quit))	\
@@ -1735,6 +1751,9 @@
       }							\
   } while (0)
 
+#endif	/* not SYNC_INPUT */
+
+
 /* Nonzero if ought to quit now.  */
 
 #define QUITP (!NILP (Vquit_flag) && NILP (Vinhibit_quit))