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:
23161ef
)
Replaced gmtime with gmtime_r
author
akallabeth
<akallabeth@posteo.net>
Mon, 25 May 2020 12:07:31 +0000
(14:07 +0200)
committer
Armin Novak
<armin.novak@thincast.com>
Mon, 22 Jun 2020 10:12:29 +0000
(12:12 +0200)
(cherry picked from commit
a45afe9db77a19e5a177fe1dc3e85119013f9587
)
winpr/libwinpr/sysinfo/sysinfo.c
patch
|
blob
|
history
diff --git
a/winpr/libwinpr/sysinfo/sysinfo.c
b/winpr/libwinpr/sysinfo/sysinfo.c
index
139d654
..
de39e15
100644
(file)
--- a/
winpr/libwinpr/sysinfo/sysinfo.c
+++ b/
winpr/libwinpr/sysinfo/sysinfo.c
@@
-213,11
+213,12
@@
void GetNativeSystemInfo(LPSYSTEM_INFO lpSystemInfo)
void GetSystemTime(LPSYSTEMTIME lpSystemTime)
{
time_t ct = 0;
+ struct tm tres;
struct tm* stm = NULL;
WORD wMilliseconds = 0;
ct = time(NULL);
wMilliseconds = (WORD)(GetTickCount() % 1000);
- stm = gmtime
(&ct
);
+ stm = gmtime
_r(&ct, &tres
);
ZeroMemory(lpSystemTime, sizeof(SYSTEMTIME));
if (stm)