Commit e9c1f811 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

comctl32/tests: Fully initialize message test data (Coverity).

parent 870de39c
......@@ -85,8 +85,8 @@ static LRESULT WINAPI editbox_subclass_proc(HWND hwnd, UINT message, WPARAM wPar
{
WNDPROC oldproc = (WNDPROC)GetWindowLongPtrA(hwnd, GWLP_USERDATA);
static LONG defwndproc_counter = 0;
struct message msg = { 0 };
LRESULT ret;
struct message msg;
msg.message = message;
msg.flags = sent|wparam|lparam;
......
......@@ -383,7 +383,7 @@ static char pszOutOfRangeItem[] = "Out Of Range Item";
static char *str_items[] =
{pszFirstItem, pszSecondItem, pszThirdItem, pszFourthItem, pszReplaceItem, pszOutOfRangeItem};
static char pszUniTestA[] = "TST";
static WCHAR pszUniTestW[] = {'T','S','T',0};
......@@ -403,15 +403,14 @@ static LRESULT WINAPI header_subclass_proc(HWND hwnd, UINT message, WPARAM wPara
{
WNDPROC oldproc = (WNDPROC)GetWindowLongPtrA(hwnd, GWLP_USERDATA);
static LONG defwndproc_counter = 0;
struct message msg = { 0 };
LRESULT ret;
struct message msg;
msg.message = message;
msg.flags = sent|wparam|lparam;
if (defwndproc_counter) msg.flags |= defwinproc;
msg.wParam = wParam;
msg.lParam = lParam;
msg.id = 0;
add_message(sequences, HEADER_SEQ_INDEX, &msg);
defwndproc_counter++;
......
......@@ -1098,7 +1098,7 @@ static void test_get_set_unicodeformat(void)
static LRESULT CALLBACK parent_wnd_proc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
static LONG defwndproc_counter = 0;
struct message msg;
struct message msg = { 0 };
LRESULT ret;
RECT rect;
HTREEITEM visibleItem;
......@@ -1110,8 +1110,6 @@ static LRESULT CALLBACK parent_wnd_proc(HWND hWnd, UINT message, WPARAM wParam,
msg.lParam = lParam;
if (message == WM_NOTIFY && lParam)
msg.id = ((NMHDR*)lParam)->code;
else
msg.id = 0;
/* log system messages, except for painting */
if (message < WM_USER &&
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment