diff options
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c index 0a5624ba1..126fa4af0 100644 --- a/src/main.c +++ b/src/main.c @@ -2243,7 +2243,7 @@ static void parseconfig(const char *filename, static void go_sleep(long ms) { -#ifdef HAVE_POLL +#ifdef HAVE_POLL_FINE /* portable subsecond "sleep" */ poll((void *)0, 0, ms); #else @@ -2259,7 +2259,7 @@ static void go_sleep(long ms) struct timeval timeout; timeout.tv_sec = ms/1000; - ms -= ms/1000; + ms = ms%1000; timeout.tv_usec = ms * 1000; select(0, NULL, NULL, NULL, &timeout); |