From 6d1a3c6e6e1ca5448812c27eded3a604d6f28583 Mon Sep 17 00:00:00 2001 From: Nikolay Sivov Date: Sat, 15 Jan 2011 18:21:54 +0300 Subject: [PATCH] comctl32/imagelist: Fix a couple of imagelist leaks (Valgrind). --- dlls/comctl32/imagelist.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/dlls/comctl32/imagelist.c b/dlls/comctl32/imagelist.c index ed92a52bb56..66cd03d6eb4 100644 --- a/dlls/comctl32/imagelist.c +++ b/dlls/comctl32/imagelist.c @@ -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; } -- 2.11.4.GIT