Robert Shearman : oleaut32: Release interfaces when told to.

Alexandre Julliard julliard at wine.codeweavers.com
Tue Feb 7 09:57:31 CST 2006


Module: wine
Branch: refs/heads/master
Commit: ec5d73910c754ba9cadc6724d217fb6779545149
URL:    http://source.winehq.org/git/?p=wine.git;a=commit;h=ec5d73910c754ba9cadc6724d217fb6779545149

Author: Robert Shearman <rob at codeweavers.com>
Date:   Tue Feb  7 16:25:42 2006 +0100

oleaut32: Release interfaces when told to.
Make the VT_DISPATCH and VT_UNKNOWN cases of serialize_param match the
TKIND_INTERFACE case below by releasing their respective interfaces as
necessary.

---

 dlls/oleaut32/tmarshal.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/dlls/oleaut32/tmarshal.c b/dlls/oleaut32/tmarshal.c
index 7c3bddc..9428995 100644
--- a/dlls/oleaut32/tmarshal.c
+++ b/dlls/oleaut32/tmarshal.c
@@ -668,11 +668,15 @@ serialize_param(
 	if (debugout) TRACE_(olerelay)("unk(0x%lx)",*arg);
 	if (writeit)
 	    hres = _marshal_interface(buf,&IID_IUnknown,(LPUNKNOWN)*arg);
+	if (dealloc)
+	    IUnknown_Release((LPUNKNOWN)*arg);
 	return hres;
     case VT_DISPATCH:
 	if (debugout) TRACE_(olerelay)("idisp(0x%lx)",*arg);
 	if (writeit)
 	    hres = _marshal_interface(buf,&IID_IDispatch,(LPUNKNOWN)*arg);
+	if (dealloc)
+	    IUnknown_Release((LPUNKNOWN)*arg);
 	return hres;
     case VT_VOID:
 	if (debugout) TRACE_(olerelay)("<void>");




More information about the wine-cvs mailing list