comctl32/imagelist: Fix a couple of imagelist leaks (Valgrind).

This commit is contained in:
Nikolay Sivov 2011-01-15 18:21:54 +03:00 committed by Alexandre Julliard
parent bf07eb926e
commit 6d1a3c6e6e
1 changed files with 10 additions and 0 deletions

View File

@ -3384,7 +3384,12 @@ static HRESULT WINAPI ImageListImpl_Merge(IImageList *iface, int i1,
/* Get the interface for the new image list */
if (hNew)
{
IImageList *imerge = (IImageList*)hNew;
ret = HIMAGELIST_QueryInterface(hNew, riid, ppv);
IImageList_Release(imerge);
}
IImageList_Release(iml2);
return ret;
@ -3534,7 +3539,12 @@ static HRESULT WINAPI ImageListImpl_GetDragImage(IImageList *iface, POINT *ppt,
/* Get the interface for the new image list */
if (hNew)
{
IImageList *idrag = (IImageList*)hNew;
ret = HIMAGELIST_QueryInterface(hNew, riid, ppv);
IImageList_Release(idrag);
}
return ret;
}