projects
/
platform
/
upstream
/
freerdp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
18e4245
)
Use GetSystemTimeAsFileTime to emulate GetTickCount64
author
Armin Novak
<armin.novak@thincast.com>
Tue, 13 Aug 2019 07:52:42 +0000
(09:52 +0200)
committer
Armin Novak
<armin.novak@thincast.com>
Tue, 13 Aug 2019 08:55:12 +0000
(10:55 +0200)
winpr/libwinpr/sysinfo/sysinfo.c
patch
|
blob
|
history
diff --git
a/winpr/libwinpr/sysinfo/sysinfo.c
b/winpr/libwinpr/sysinfo/sysinfo.c
index
33f2534
..
3f984f7
100644
(file)
--- a/
winpr/libwinpr/sysinfo/sysinfo.c
+++ b/
winpr/libwinpr/sysinfo/sysinfo.c
@@
-529,7
+529,12
@@
ULONGLONG winpr_GetTickCount64(void)
ticks = (ts.tv_sec * 1000) + (ts.tv_nsec / 1000000);
#elif defined(_WIN32)
- ticks = (ULONGLONG) GetTickCount();
+ FILETIME ft;
+ ULARGE_INTEGER ul;
+ GetSystemTimeAsFileTime(&ft);
+ ul.LowPart = ft.dwLowDateTime;
+ ul.HighPart = ft.dwHighDateTime;
+ ticks = ul.QuadPart;
#else
/**
* FIXME: this is relative to the Epoch time, and we