From: Richard M. Stallman Date: Fri, 13 Jun 1997 00:45:19 +0000 (+0000) Subject: (wait_reading_process_input): Return if unread events appear. X-Git-Tag: emacs-20.1~1716 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=69645afc5310cb5cad6fc6769de55e9102ffaaa9;p=emacs.git (wait_reading_process_input): Return if unread events appear. --- diff --git a/src/process.c b/src/process.c index 1b8174299ff..a9da5b1f725 100644 --- a/src/process.c +++ b/src/process.c @@ -2248,6 +2248,11 @@ wait_reading_process_input (time_limit, microsecs, read_kbd, do_display) goto retry; } + /* If there is unread keyboard input, also return. */ + if (XINT (read_kbd) != 0 + && requeued_events_pending_p ()) + break; + if (! EMACS_TIME_NEG_P (timer_delay) && time_limit != -1) { EMACS_TIME difference; @@ -2408,6 +2413,11 @@ wait_reading_process_input (time_limit, microsecs, read_kbd, do_display) break; } + /* If there is unread keyboard input, also return. */ + if (XINT (read_kbd) != 0 + && requeued_events_pending_p ()) + break; + /* If wait_for_cell. check for keyboard input but don't run any timers. ??? (It seems wrong to me to check for keyboard