Module: wine Branch: master Commit: 8591c2ac1a12f10a3447916999b1f61cf89ef197 URL: https://source.winehq.org/git/wine.git/?a=commit;h=8591c2ac1a12f10a344791699...
Author: Rémi Bernon rbernon@codeweavers.com Date: Wed Mar 10 12:22:31 2021 +0100
ntdll/tests: Fix tick count read from user shared data.
Signed-off-by: Rémi Bernon rbernon@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/ntdll/tests/time.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/ntdll/tests/time.c b/dlls/ntdll/tests/time.c index d756a8c839c..931bf765aa7 100644 --- a/dlls/ntdll/tests/time.c +++ b/dlls/ntdll/tests/time.c @@ -206,9 +206,9 @@ static void test_user_shared_data_time(void) { t1 = GetTickCount(); if (user_shared_data->NtMajorVersion <= 5 && user_shared_data->NtMinorVersion <= 1) - t2 = (*(volatile ULONG*)&user_shared_data->TickCountLowDeprecated * (ULONG64)user_shared_data->TickCountMultiplier) >> 24; + t2 = (DWORD)((*(volatile ULONG*)&user_shared_data->TickCountLowDeprecated * (ULONG64)user_shared_data->TickCountMultiplier) >> 24); else - t2 = (read_ksystem_time(&user_shared_data->u.TickCount) * user_shared_data->TickCountMultiplier) >> 24; + t2 = (DWORD)((read_ksystem_time(&user_shared_data->u.TickCount) * user_shared_data->TickCountMultiplier) >> 24); t3 = GetTickCount(); } while(t3 < t1 && i++ < 1); /* allow for wrap, but only once */