Skip to content

Commit

Permalink
fix build, second try
Browse files Browse the repository at this point in the history
  • Loading branch information
nihui committed Mar 6, 2018
1 parent 5f0fa95 commit 5e484a4
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,10 @@ double get_current_time()
time = ((uint64_t)file_time.dwLowDateTime ) ;
time += ((uint64_t)file_time.dwHighDateTime) << 32;

struct timeval tv;

tv.tv_sec = (long) ((time - EPOCH) / 10000000L);
tv.tv_usec = (long) (system_time.wMilliseconds * 1000);
long tv_sec = (long) ((time - EPOCH) / 10000000L);
long tv_usec = (long) (system_time.wMilliseconds * 1000);

return tv.tv_sec * 1000.0 + tv.tv_usec / 1000.0;
return tv_sec * 1000.0 + tv_usec / 1000.0;
}
#else // _WIN32
double get_current_time()
Expand Down

0 comments on commit 5e484a4

Please sign in to comment.