# 37239
r = mkaply, a = brendan OS/2 bringup continues on M16 - port memory leak fix - OS/2 only git-svn-id: svn://10.0.0.236/trunk@71081 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -221,3 +221,34 @@ nsresult nsPluginFile::GetPluginInfo( nsPluginInfo &info)
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
nsresult nsPluginFile::FreePluginInfo(nsPluginInfo& info)
|
||||
{
|
||||
if(info.fName != nsnull)
|
||||
PL_strfree(info.fName);
|
||||
|
||||
if(info.fDescription != nsnull)
|
||||
PL_strfree(info.fDescription);
|
||||
|
||||
if(info.fMimeType != nsnull)
|
||||
PL_strfree(info.fMimeType);
|
||||
|
||||
if(info.fMimeDescription != nsnull)
|
||||
PL_strfree(info.fMimeDescription);
|
||||
|
||||
if(info.fExtensions != nsnull)
|
||||
PL_strfree(info.fExtensions);
|
||||
|
||||
if(info.fMimeTypeArray != nsnull)
|
||||
PR_Free(info.fMimeTypeArray);
|
||||
|
||||
if(info.fMimeDescriptionArray != nsnull)
|
||||
PR_Free(info.fMimeDescriptionArray);
|
||||
|
||||
if(info.fExtensionArray != nsnull)
|
||||
PR_Free(info.fExtensionArray);
|
||||
|
||||
memset((void *)&info, 0, sizeof(info));
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
@@ -221,3 +221,34 @@ nsresult nsPluginFile::GetPluginInfo( nsPluginInfo &info)
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
nsresult nsPluginFile::FreePluginInfo(nsPluginInfo& info)
|
||||
{
|
||||
if(info.fName != nsnull)
|
||||
PL_strfree(info.fName);
|
||||
|
||||
if(info.fDescription != nsnull)
|
||||
PL_strfree(info.fDescription);
|
||||
|
||||
if(info.fMimeType != nsnull)
|
||||
PL_strfree(info.fMimeType);
|
||||
|
||||
if(info.fMimeDescription != nsnull)
|
||||
PL_strfree(info.fMimeDescription);
|
||||
|
||||
if(info.fExtensions != nsnull)
|
||||
PL_strfree(info.fExtensions);
|
||||
|
||||
if(info.fMimeTypeArray != nsnull)
|
||||
PR_Free(info.fMimeTypeArray);
|
||||
|
||||
if(info.fMimeDescriptionArray != nsnull)
|
||||
PR_Free(info.fMimeDescriptionArray);
|
||||
|
||||
if(info.fExtensionArray != nsnull)
|
||||
PR_Free(info.fExtensionArray);
|
||||
|
||||
memset((void *)&info, 0, sizeof(info));
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user