oleview: Added data freeing in EnumFuncs function.

This commit is contained in:
Piotr Caban 2006-08-25 23:25:07 +02:00 committed by Alexandre Julliard
parent bc06d70770
commit e213b7e8aa
1 changed files with 5 additions and 1 deletions

View File

@ -448,7 +448,11 @@ int EnumFuncs(ITypeInfo *pTypeInfo, int cFuncs, HTREEITEM hParent)
bstrParamNames = HeapAlloc(GetProcessHeap(), 0, bstrParamNames = HeapAlloc(GetProcessHeap(), 0,
sizeof(BSTR*)*(pFuncDesc->cParams+1)); sizeof(BSTR*)*(pFuncDesc->cParams+1));
if(FAILED(ITypeInfo_GetNames(pTypeInfo, pFuncDesc->memid, bstrParamNames, if(FAILED(ITypeInfo_GetNames(pTypeInfo, pFuncDesc->memid, bstrParamNames,
pFuncDesc->cParams+1, &namesNo))) continue; pFuncDesc->cParams+1, &namesNo)))
{
HeapFree(GetProcessHeap(), 0, bstrParamNames);
continue;
}
SysFreeString(bstrParamNames[0]); SysFreeString(bstrParamNames[0]);
memset(wszText, 0, sizeof(wszText)); memset(wszText, 0, sizeof(wszText));