diff options
Diffstat (limited to 'src/microhttpd/mhd_mono_clock.c')
-rw-r--r-- | src/microhttpd/mhd_mono_clock.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/microhttpd/mhd_mono_clock.c b/src/microhttpd/mhd_mono_clock.c index 55249be3..2f2961d6 100644 --- a/src/microhttpd/mhd_mono_clock.c +++ b/src/microhttpd/mhd_mono_clock.c | |||
@@ -88,8 +88,8 @@ static hrtime_t hrtime_start; | |||
88 | #if _WIN32_WINNT >= 0x0600 | 88 | #if _WIN32_WINNT >= 0x0600 |
89 | static uint64_t tick_start; | 89 | static uint64_t tick_start; |
90 | #else /* _WIN32_WINNT < 0x0600 */ | 90 | #else /* _WIN32_WINNT < 0x0600 */ |
91 | static int64_t perf_freq; | 91 | static uint64_t perf_freq; |
92 | static int64_t perf_start; | 92 | static uint64_t perf_start; |
93 | #endif /* _WIN32_WINNT < 0x0600 */ | 93 | #endif /* _WIN32_WINNT < 0x0600 */ |
94 | #endif /* _WIN32 */ | 94 | #endif /* _WIN32 */ |
95 | 95 | ||
@@ -283,8 +283,8 @@ MHD_monotonic_sec_counter_init (void) | |||
283 | 283 | ||
284 | QueryPerformanceFrequency (&freq); /* never fail on XP and later */ | 284 | QueryPerformanceFrequency (&freq); /* never fail on XP and later */ |
285 | QueryPerformanceCounter (&perf_counter); /* never fail on XP and later */ | 285 | QueryPerformanceCounter (&perf_counter); /* never fail on XP and later */ |
286 | perf_freq = freq.QuadPart; | 286 | perf_freq = (uint64_t) freq.QuadPart; |
287 | perf_start = perf_counter.QuadPart; | 287 | perf_start = (uint64_t) perf_counter.QuadPart; |
288 | mono_clock_source = _MHD_CLOCK_PERFCOUNTER; | 288 | mono_clock_source = _MHD_CLOCK_PERFCOUNTER; |
289 | } | 289 | } |
290 | else | 290 | else |
@@ -391,7 +391,7 @@ MHD_monotonic_sec_counter (void) | |||
391 | LARGE_INTEGER perf_counter; | 391 | LARGE_INTEGER perf_counter; |
392 | 392 | ||
393 | QueryPerformanceCounter (&perf_counter); /* never fail on XP and later */ | 393 | QueryPerformanceCounter (&perf_counter); /* never fail on XP and later */ |
394 | return (time_t) (((uint64_t) (perf_counter.QuadPart - perf_start)) | 394 | return (time_t) (((uint64_t) perf_counter.QuadPart - perf_start) |
395 | / perf_freq); | 395 | / perf_freq); |
396 | } | 396 | } |
397 | #endif /* _WIN32_WINNT < 0x0600 */ | 397 | #endif /* _WIN32_WINNT < 0x0600 */ |