diff --git a/compat/mingw.c b/compat/mingw.c
index ccfa2a0a3d3263862beb0d2796be1aba78574986..7eed60db1b10cc303f37e1bf3307058af94b8f9d 100644 (file)
--- a/compat/mingw.c
+++ b/compat/mingw.c
{
int i, pending;
- if (timeout != -1)
+ if (timeout >= 0) {
+ if (nfds == 0) {
+ Sleep(timeout);
+ return 0;
+ }
return errno = EINVAL, error("poll timeout not supported");
+ }
/* When there is only one fd to wait for, then we pretend that
* input is available and let the actual wait happen when the