Skip to content

Commit

Permalink
added needed #ifdef WIN32. Thanks, alflanagan!
Browse files Browse the repository at this point in the history
  • Loading branch information
Bob Burger committed Sep 22, 2016
1 parent 15982a2 commit 7728f94
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions c/stats.c
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,7 @@ ptr S_realtime(void) {
/******** initialization ********/

void S_stats_init() {
#ifdef WIN32
/* Use GetSystemTimePreciseAsFileTime when available (Windows 8 and later). */
HMODULE h = LoadLibrary("kernel32.dll");
if (h != NULL) {
Expand All @@ -472,5 +473,6 @@ void S_stats_init() {
else
FreeLibrary(h);
}
#endif
s_gettime(time_monotonic, &starting_mono_tp);
}

0 comments on commit 7728f94

Please sign in to comment.