Fix a mem leak. r=jband

This commit is contained in:
gagan%netscape.com 2000-03-16 23:31:53 +00:00
parent b40b1b9d75
commit e1b0d2b26c

View File

@ -442,11 +442,11 @@ nsJSIID::FillCache(JSContext *cx, JSObject *obj,
nsIXPCScriptable *arbitrary)
{
nsIInterfaceInfoManager* iim = nsnull;
nsIInterfaceInfo* iinfo;
nsCOMPtr<nsIInterfaceInfo> iinfo;
PRUint16 count;
if(!(iim = XPTI_GetInterfaceInfoManager()) ||
NS_FAILED(iim->GetInfoForIID(mDetails.GetID(), &iinfo)) ||
NS_FAILED(iim->GetInfoForIID(mDetails.GetID(), getter_AddRefs(iinfo))) ||
!iinfo ||
NS_FAILED(iinfo->GetConstantCount(&count)))