coverity#705676: fix memory leak

Change-Id: Ibae1a0d073249ecfbfee0f73473d66bbf2602aff
This commit is contained in:
Markus Mohrhard
2013-03-09 17:19:01 +01:00
parent 7657115dd9
commit 5f606b0a5b

View File

@@ -178,14 +178,17 @@ sal_Bool DoClassHeader( RSCHEADER * pHeader, sal_Bool bMember )
else
S.Push( pHeader->pClass->Create( NULL, RSCINST() ) );
ObjNode * pNode = new ObjNode( aName1, S.Top().pData,
pFI->GetFileIndex() );
pTC->pEH->StdOut( ".", RscVerbosityVerbose );
if( !aName1.IsId() )
pTC->pEH->Error( ERR_IDEXPECTED, pHeader->pClass, aName1 );
else if( !pHeader->pClass->PutObjNode( pNode ) )
pTC->pEH->Error( ERR_DOUBLEID, pHeader->pClass, aName1 );
else
{
ObjNode * pNode = new ObjNode( aName1, S.Top().pData,
pFI->GetFileIndex() );
if( !pHeader->pClass->PutObjNode( pNode ) )
pTC->pEH->Error( ERR_DOUBLEID, pHeader->pClass, aName1 );
}
}
else
{