summaryrefslogtreecommitdiff
path: root/src/dispnew.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/dispnew.c')
-rw-r--r--src/dispnew.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/dispnew.c b/src/dispnew.c
index 102a8f28e64..fbfe3b702e7 100644
--- a/src/dispnew.c
+++ b/src/dispnew.c
@@ -1860,6 +1860,9 @@ sit_for (sec, usec, reading, display)
if (display)
redisplay_preserve_echo_area ();
+ if (sec == 0 && usec == 0)
+ return Qt;
+
#ifdef SIGIO
gobble_input ();
#endif
@@ -1907,10 +1910,6 @@ Value is t if waited the full time with no input arriving.")
CHECK_NUMBER (arg, 0);
- sec = XINT (arg);
- if (sec <= 0)
- return Qt;
-
if (!NILP (millisec))
{
#ifndef EMACS_HAS_USECS