---
 wmload/wmload.c | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/wmload/wmload.c b/wmload/wmload.c
index d593205..025460d 100644
--- a/wmload/wmload.c
+++ b/wmload/wmload.c
@@ -1,3 +1,5 @@
+#define _POSIX_C_SOURCE 199309L
+
 #include <stdio.h>
 #include <string.h>
 #include <unistd.h>
@@ -342,7 +344,13 @@ int main(int argc,char *argv[])
 #ifdef SYSV
       poll((struct poll *) 0, (size_t) 0, 50);
 #else
-      usleep(50000L);                  /* 5/100 sec */
+      {
+        struct timespec ts;
+
+        ts.tv_sec = 0;
+        ts.tv_nsec = 50000000L;        /* 5/100 sec */
+        nanosleep(&ts, NULL);
+      }
 #endif
     }
   return 0;
-- 
2.1.0


-- 
To unsubscribe, send mail to wmaker-dev-unsubscr...@lists.windowmaker.org.

Reply via email to