mirror of
https://github.com/cuberite/libevent.git
synced 2025-09-11 13:24:43 -04:00
Restore accidentally disabled nanosleep implementation of evutil_usleep.
This commit is contained in:
parent
da455e92f5
commit
0d1611dc3e
4
evutil.c
4
evutil.c
@ -76,8 +76,8 @@
|
|||||||
#endif
|
#endif
|
||||||
#ifndef EVENT__HAVE_GETTIMEOFDAY
|
#ifndef EVENT__HAVE_GETTIMEOFDAY
|
||||||
#include <sys/timeb.h>
|
#include <sys/timeb.h>
|
||||||
#include <time.h>
|
|
||||||
#endif
|
#endif
|
||||||
|
#include <time.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#ifdef EVENT__HAVE_IFADDRS_H
|
#ifdef EVENT__HAVE_IFADDRS_H
|
||||||
#include <ifaddrs.h>
|
#include <ifaddrs.h>
|
||||||
@ -2359,7 +2359,7 @@ evutil_usleep_(const struct timeval *tv)
|
|||||||
long msec = evutil_tv_to_msec_(tv);
|
long msec = evutil_tv_to_msec_(tv);
|
||||||
Sleep((DWORD)msec);
|
Sleep((DWORD)msec);
|
||||||
}
|
}
|
||||||
#elif defined(EVENT__HAVE_NANOSLEEP_XXX)
|
#elif defined(EVENT__HAVE_NANOSLEEP)
|
||||||
{
|
{
|
||||||
struct timespec ts;
|
struct timespec ts;
|
||||||
ts.tv_sec = tv->tv_sec;
|
ts.tv_sec = tv->tv_sec;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user