nanosecond: initial commit changing timeval to timespec
[fio.git] / os / windows / posix.c
index eae8c86170b958254bd8a2bc14c7015f801ac8d7..488d0ed2c44e16bd1bd82c447b9affb67e567987 100755 (executable)
@@ -25,8 +25,8 @@
 #include "../os-windows.h"
 #include "../../lib/hweight.h"
 
-extern unsigned long mtime_since_now(struct timeval *);
-extern void fio_gettime(struct timeval *, void *);
+extern unsigned long mtime_since_now(struct timespec *);
+extern void fio_gettime(struct timespec *, void *);
 
 /* These aren't defined in the MinGW headers */
 HRESULT WINAPI StringCchCopyA(
@@ -852,7 +852,7 @@ int poll(struct pollfd fds[], nfds_t nfds, int timeout)
 
 int nanosleep(const struct timespec *rqtp, struct timespec *rmtp)
 {
-       struct timeval tv;
+       struct timespec tv;
        DWORD ms_remaining;
        DWORD ms_total = (rqtp->tv_sec * 1000) + (rqtp->tv_nsec / 1000000.0);