summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2002-01-02 12:12:41 +0000
committerEric Andersen <andersen@codepoet.org>2002-01-02 12:12:41 +0000
commitcac4a2ef934d7ac5314c874b88b62e922fc70690 (patch)
treeea2aef0ee434525e67c87d9a1f63a7fffd60621a
parent5572db65ce5a2d0d159ec3ba20d47934303915cb (diff)
Take the shorcut version, which is good enough for
nearly all normal usage. -Erik
-rw-r--r--libc/unistd/sleep.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/unistd/sleep.c b/libc/unistd/sleep.c
index f67d969e3..f8c57fc89 100644
--- a/libc/unistd/sleep.c
+++ b/libc/unistd/sleep.c
@@ -23,14 +23,14 @@
#include <signal.h>
#include <unistd.h>
-#if 0
+#if 1
/* This is a quick and dirty, but not 100% compliant with
* the stupid SysV SIGCHLD vs. SIG_IGN behaviour. It is
* fine unless you are messing with SIGCHLD... */
unsigned int sleep (unsigned int sec)
{
struct timespec ts = {
- tv_sec: (long int)(sec / 1000000),
+ tv_sec: (long int) sec,
tv_nsec: 0
};
nanosleep(&ts, &ts);