Skip to content
Snippets Groups Projects
Commit 520bd9e4 authored by Marc Hoersken's avatar Marc Hoersken
Browse files

tests first.c: fix calculation of sleep timeout on Windows

Not converting to double caused small timeouts to be skipped.
parent 24cf20ec
No related branches found
No related tags found
No related merge requests found
......@@ -56,7 +56,7 @@ int select_wrapper(int nfds, fd_set *rd, fd_set *wr, fd_set *exc,
* select() can not be used to sleep without a single fd_set.
*/
if(!nfds) {
Sleep(1000*tv->tv_sec + tv->tv_usec/1000);
Sleep((1000*tv->tv_sec) + (DWORD)(((double)tv->tv_usec)/1000.0));
return 0;
}
#endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment