Nikolay Sivov : ole32: Fix a leak when creating antimoniker through activation.

Alexandre Julliard julliard at winehq.org
Tue Jun 2 08:11:18 CDT 2020


Module: wine
Branch: stable
Commit: 61eb313094727b0d5babe7d595fba45701514925
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=61eb313094727b0d5babe7d595fba45701514925

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Thu Jan 30 14:53:46 2020 +0300

ole32: Fix a leak when creating antimoniker through activation.

Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
(cherry picked from commit 82044449c45d4037dae393bc348579e87d9c4b10)
Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>

---

 dlls/ole32/antimoniker.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/dlls/ole32/antimoniker.c b/dlls/ole32/antimoniker.c
index f7912fad78..3cf2e00b26 100644
--- a/dlls/ole32/antimoniker.c
+++ b/dlls/ole32/antimoniker.c
@@ -646,9 +646,7 @@ HRESULT WINAPI AntiMoniker_CreateInstance(IClassFactory *iface,
         return hr;
 
     hr = IMoniker_QueryInterface(pMoniker, riid, ppv);
-
-    if (FAILED(hr))
-        IMoniker_Release(pMoniker);
+    IMoniker_Release(pMoniker);
 
     return hr;
 }




More information about the wine-cvs mailing list