Zebediah Figura : ntdll/tests: Avoid passing an uninitialized timeout to NtNotifyChangeKey().
Alexandre Julliard
julliard at winehq.org
Wed Feb 24 15:45:39 CST 2021
Module: wine
Branch: master
Commit: db0fe3381310ba7613a7458f25ce5610cc6091c4
URL: https://source.winehq.org/git/wine.git/?a=commit;h=db0fe3381310ba7613a7458f25ce5610cc6091c4
Author: Zebediah Figura <z.figura12 at gmail.com>
Date: Tue Feb 23 19:40:01 2021 -0600
ntdll/tests: Avoid passing an uninitialized timeout to NtNotifyChangeKey().
Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/ntdll/tests/reg.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/dlls/ntdll/tests/reg.c b/dlls/ntdll/tests/reg.c
index ac1dec9f2f8..7463f98aa29 100644
--- a/dlls/ntdll/tests/reg.c
+++ b/dlls/ntdll/tests/reg.c
@@ -1850,7 +1850,7 @@ static void test_NtQueryKey(void)
static void test_notify(void)
{
OBJECT_ATTRIBUTES attr;
- LARGE_INTEGER timeout;
+ static const LARGE_INTEGER timeout;
IO_STATUS_BLOCK iosb;
UNICODE_STRING str;
HANDLE key, key2, events[4], subkey;
@@ -1952,7 +1952,6 @@ static void test_notify(void)
status = pNtNotifyChangeMultipleKeys(key, 0, NULL, events[0], NULL, NULL, &iosb, REG_NOTIFY_CHANGE_NAME, FALSE, NULL, 0, TRUE);
ok(status == STATUS_PENDING, "NtNotifyChangeKey returned %x\n", status);
- timeout.QuadPart = 0;
status = pNtWaitForSingleObject(events[0], FALSE, &timeout);
ok(status == STATUS_TIMEOUT, "NtWaitForSingleObject returned %x\n", status);
More information about the wine-cvs
mailing list