Commit 67963a76 authored by Hans Leidekker's avatar Hans Leidekker Committed by Alexandre Julliard

fusion: Fix some memory leaks.

Found by Valgrind.
parent 952cd1d3
......@@ -471,6 +471,11 @@ static HRESULT parse_display_name(IAssemblyNameImpl *name, LPCWSTR szAssemblyNam
done:
HeapFree(GetProcessHeap(), 0, save);
if (FAILED(hr))
{
HeapFree(GetProcessHeap(), 0, name->displayname);
HeapFree(GetProcessHeap(), 0, name->name);
}
return hr;
}
......
......@@ -209,6 +209,8 @@ static void test_CreateAssemblyEnum(void)
ok(hr == E_INVALIDARG, "Expected E_INVALIDARG, got %08x\n", hr);
ok(asmenum == (IAssemblyEnum *)0xdeadbeef,
"Expected asmenum to be unchanged, got %p\n", asmenum);
IAssemblyName_Release(asmname);
}
typedef struct _tagASMNAME
......
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