Kaydet (Commit) ad02b999 authored tarafından Markus Mohrhard's avatar Markus Mohrhard

coverity: fix memory leak

Change-Id: I3aed29393376933fe6f07e38fb936911723ed2fe
üst b7538690
...@@ -4128,9 +4128,9 @@ sal_Int32 SAL_CALL ScCellRangesBase::replaceAll( const uno::Reference<util::XSea ...@@ -4128,9 +4128,9 @@ sal_Int32 SAL_CALL ScCellRangesBase::replaceAll( const uno::Reference<util::XSea
for (; itr != itrEnd && *itr < nTabCount; ++itr) for (; itr != itrEnd && *itr < nTabCount; ++itr)
if ( *itr != nTab && bUndo) if ( *itr != nTab && bUndo)
pUndoDoc->AddUndoTab( *itr, *itr ); pUndoDoc->AddUndoTab( *itr, *itr );
ScMarkData* pUndoMark = NULL; boost::scoped_ptr<ScMarkData> pUndoMark;
if (bUndo) if (bUndo)
pUndoMark = new ScMarkData(aMark); pUndoMark.reset(new ScMarkData(aMark));
bool bFound = false; bool bFound = false;
if (bUndo) if (bUndo)
...@@ -4153,7 +4153,6 @@ sal_Int32 SAL_CALL ScCellRangesBase::replaceAll( const uno::Reference<util::XSea ...@@ -4153,7 +4153,6 @@ sal_Int32 SAL_CALL ScCellRangesBase::replaceAll( const uno::Reference<util::XSea
else else
{ {
delete pUndoDoc; delete pUndoDoc;
delete pUndoMark;
// nReplaced bleibt 0 // nReplaced bleibt 0
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment