mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-01-29 21:33:02 +00:00
fix win32 ms time fail
`GetSystemTimeAsFileTime` returns 100 nano seconds elapsed time, not 100 micro seconds. Signed-off-by: Jerry Yu <jerry.h.yu@arm.com>
This commit is contained in:
parent
02d684061b
commit
f52078f5a1
@ -200,7 +200,7 @@ mbedtls_ms_time_t mbedtls_ms_time(void)
|
||||
|
||||
GetSystemTimeAsFileTime(&ct);
|
||||
current_ms = ((mbedtls_ms_time_t) ct.dwLowDateTime +
|
||||
((mbedtls_ms_time_t) (ct.dwHighDateTime) << 32LL))/10;
|
||||
((mbedtls_ms_time_t) (ct.dwHighDateTime) << 32LL))/10000;
|
||||
return current_ms;
|
||||
}
|
||||
#else
|
||||
|
Loading…
x
Reference in New Issue
Block a user