Paul Gofman : hnetcfg/tests: Don't leak IEnumVARIANT reference in test_static_port_mapping_collection().

Alexandre Julliard julliard at winehq.org
Thu Feb 3 16:06:57 CST 2022


Module: wine
Branch: master
Commit: 69acffb95424c06e8f9eacfa9fe9969e2ae3261c
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=69acffb95424c06e8f9eacfa9fe9969e2ae3261c

Author: Paul Gofman <pgofman at codeweavers.com>
Date:   Thu Feb  3 14:28:33 2022 +0300

hnetcfg/tests: Don't leak IEnumVARIANT reference in test_static_port_mapping_collection().

Signed-off-by: Paul Gofman <pgofman at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/hnetcfg/tests/policy.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/dlls/hnetcfg/tests/policy.c b/dlls/hnetcfg/tests/policy.c
index b6b353ac87d..f344019d1d3 100644
--- a/dlls/hnetcfg/tests/policy.c
+++ b/dlls/hnetcfg/tests/policy.c
@@ -188,6 +188,7 @@ static void test_static_port_mapping_collection( IStaticPortMappingCollection *p
 
     hr = IUnknown_QueryInterface(unk, &IID_IEnumVARIANT, (void **)&enum_ports);
     ok(hr == S_OK, "Got unexpected hr %#x.\n", hr);
+    IUnknown_Release( unk );
 
     refcount2 = get_refcount((IUnknown *)ports);
     ok(refcount2 == refcount, "Got unexpected refcount %u, refcount2 %u.\n", refcount, refcount2);




More information about the wine-cvs mailing list