Mercurial > emacs
changeset 34660:75866a7ebaec
(wait_reading_process_input): Check for pending
input when running timers.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Mon, 18 Dec 2000 10:53:51 +0000 |
parents | 7085cd9344ce |
children | ef8413670ea4 |
files | src/process.c |
diffstat | 1 files changed, 22 insertions(+), 20 deletions(-) [+] |
line wrap: on
line diff
--- a/src/process.c Mon Dec 18 10:27:06 2000 +0000 +++ b/src/process.c Mon Dec 18 10:53:51 2000 +0000 @@ -2436,18 +2436,19 @@ if (! wait_for_cell) { EMACS_TIME timer_delay; - int old_timers_run; - - retry: - old_timers_run = timers_run; - timer_delay = timer_check (1); - if (timers_run != old_timers_run && do_display) + + do { - redisplay_preserve_echo_area (); - /* We must retry, since a timer may have requeued itself - and that could alter the time_delay. */ - goto retry; + int old_timers_run = timers_run; + timer_delay = timer_check (1); + if (timers_run != old_timers_run && do_display) + /* We must retry, since a timer may have requeued itself + and that could alter the time_delay. */ + redisplay_preserve_echo_area (); + else + break; } + while (!detect_input_pending ()); /* If there is unread keyboard input, also return. */ if (XINT (read_kbd) != 0 @@ -4785,18 +4786,19 @@ if (! wait_for_cell) { EMACS_TIME timer_delay; - int old_timers_run; - - retry: - old_timers_run = timers_run; - timer_delay = timer_check (1); - if (timers_run != old_timers_run && do_display) + + do { - redisplay_preserve_echo_area (); - /* We must retry, since a timer may have requeued itself - and that could alter the time delay. */ - goto retry; + int old_timers_run = timers_run; + timer_delay = timer_check (1); + if (timers_run != old_timers_run && do_display) + /* We must retry, since a timer may have requeued itself + and that could alter the time delay. */ + redisplay_preserve_echo_area (); + else + break; } + while (!detect_input_pending ()); /* If there is unread keyboard input, also return. */ if (XINT (read_kbd) != 0