Skip to content

Commit

Permalink
Revert "fix: timestamp resolution to microseconds on Windows (getsent…
Browse files Browse the repository at this point in the history
  • Loading branch information
dacap committed Oct 7, 2024
1 parent dbb9580 commit 978cb60
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/sentry_utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,9 @@ sentry__usec_time(void)
// Contains a 64-bit value representing the number of 100-nanosecond
// intervals since January 1, 1601 (UTC).
FILETIME file_time;
# if _WIN32_WINNT >= 0x0602
GetSystemTimePreciseAsFileTime(&file_time);
# else
GetSystemTimeAsFileTime(&file_time);
# endif
SYSTEMTIME system_time;
GetSystemTime(&system_time);
SystemTimeToFileTime(&system_time, &file_time);

uint64_t timestamp = (uint64_t)file_time.dwLowDateTime
+ ((uint64_t)file_time.dwHighDateTime << 32);
Expand Down

0 comments on commit 978cb60

Please sign in to comment.