From 053b6b21b66b11c2a5d9d05f7fd0267d74c60240 Mon Sep 17 00:00:00 2001 From: Rob Shearman Date: Mon, 23 Oct 2006 11:44:50 +0100 Subject: [PATCH] oleaut32: Fix two more leaks on type info destruction. --- dlls/oleaut32/typelib.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/oleaut32/typelib.c b/dlls/oleaut32/typelib.c index e09a5d5f8c4..d866b9b2837 100644 --- a/dlls/oleaut32/typelib.c +++ b/dlls/oleaut32/typelib.c @@ -1816,7 +1816,7 @@ MSFT_DoFuncs(TLBContext* pcx, { if ( pFuncRec->FKCCIC & 0x2000 ) { - (*pptfd)->Entry = (WCHAR*) pFuncRec->OptAttr[2] ; + (*pptfd)->Entry = SysAllocString((WCHAR*)pFuncRec->OptAttr[2]); } else { @@ -3593,6 +3593,8 @@ static ULONG WINAPI ITypeLib2_fnRelease( ITypeLib2 *iface) for (pImpLib = This->pImpLibs; pImpLib; pImpLib = pImpLibNext) { + if (pImpLib->pImpTypeLib) + ITypeLib_Release((ITypeLib *)pImpLib->pImpTypeLib); TLB_Free(pImpLib->name); pImpLibNext = pImpLib->next; @@ -4433,6 +4435,7 @@ static ULONG WINAPI ITypeInfo_fnRelease(ITypeInfo2 *iface) pCustDataNext = pCustData->next; TLB_Free(pCustData); } + SysFreeString(pFInfo->Entry); SysFreeString(pFInfo->HelpString); SysFreeString(pFInfo->Name);