4 #include <netlistmgr.h>
6 #define WIN32_LEAN_AND_MEAN
43 static int gettimeofday(timeval * tp,
struct timezone * tzp)
45 static const uint64_t EPOCH = ((uint64_t)116444736000000000ULL);
47 SYSTEMTIME system_time;
51 GetSystemTime(&system_time);
52 SystemTimeToFileTime(&system_time, &file_time);
53 time = ((uint64_t)file_time.dwLowDateTime);
54 time += ((uint64_t)file_time.dwHighDateTime) << 32;
56 tp->tv_sec = (long)((time - EPOCH) / 10000000L);
57 tp->tv_usec = (long)(system_time.wMilliseconds * 1000);