From a0c18ce7849a192d4803fe08d65144bf914331ea Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Mon, 24 Mar 2008 13:06:48 +0100 Subject: [PATCH] user32/tests: Fix uninitialized struct component. --- dlls/user32/tests/msg.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c index 7aa99b4624a..b8d93753606 100644 --- a/dlls/user32/tests/msg.c +++ b/dlls/user32/tests/msg.c @@ -7176,14 +7176,16 @@ static LRESULT CALLBACK cbt_global_hook_proc(int nCode, WPARAM wParam, LPARAM lP /* WH_MOUSE_LL hook */ if (nCode == HC_ACTION) { - struct message msg; MSLLHOOKSTRUCT *mhll = (MSLLHOOKSTRUCT *)lParam; /* we can't test for real mouse events */ if (mhll->flags & LLMHF_INJECTED) { + struct message msg; + + memset (&msg, 0, sizeof (msg)); msg.message = wParam; - msg.flags = hook; + msg.flags = hook; add_message(&msg); } return CallNextHookEx(hCBT_global_hook, nCode, wParam, lParam);