[SHELL32_APITEST]

* Plug some leaks. CIDs 1106362, 1106363 and 1106364.
CORE-7975

svn path=/trunk/; revision=62474
This commit is contained in:
Amine Khaldi 2014-03-11 13:06:09 +00:00
parent 3bce7d16d7
commit 2c26c653a9

View file

@ -11,7 +11,11 @@ BOOL CheckWindowClass(HWND hwnd, PCWSTR className)
{
ULONG size = (wcslen(className) + 1)* sizeof(WCHAR);
PWCHAR buffer = (PWCHAR)malloc(size);
if (GetClassNameW(hwnd, buffer, size ) == 0) return FALSE;
if (GetClassNameW(hwnd, buffer, size ) == 0)
{
free(buffer);
return FALSE;
}
int res = wcscmp(buffer, className);
free(buffer);
return res == 0;
@ -161,6 +165,7 @@ void test_CShellMenu()
if (!CreateCShellMenu(&shellMenu, &dockingMenu, &menuWithSite))
{
skip("failed to create CShellMenuObject\n");
delete dummyWindow;
return;
}
@ -288,6 +293,7 @@ void test_CShellMenu_callbacks(IShellFolder *shellFolder, HMENU hmenu)
if (!CreateCShellMenu(&shellMenu, &dockingMenu, &menuWithSite))
{
skip("failed to create CShellMenuObject\n");
delete dummyWindow;
return;
}