Kaydet (Commit) da5ac820 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#704376 Logically dead code

Change-Id: I4ab6a73a0b24db2d07c33cd593b0898b87c90fd3
üst a79afdaa
......@@ -453,16 +453,11 @@ sal_Bool SwTOXMgr::UpdateOrInsertTOX(const SwTOXDescription& rDesc,
if (pDoc->GetIDocumentUndoRedo().DoesUndo())
{
if (pNewTOX != NULL)
{
pDoc->GetIDocumentUndoRedo().DelAllUndoObj();
}
pDoc->GetIDocumentUndoRedo().DelAllUndoObj();
pDoc->GetIDocumentUndoRedo().StartUndo(UNDO_TOXCHANGE, NULL);
}
if (pNewTOX != NULL) // => pTOX != NULL
pDoc->ChgTOX(*pTOX, *pNewTOX);
pDoc->ChgTOX(*pTOX, *pNewTOX);
pTOX->DisableKeepExpression();
bRet = pSh->UpdateTableOf(*pTOX, pSet);
......@@ -471,11 +466,6 @@ sal_Bool SwTOXMgr::UpdateOrInsertTOX(const SwTOXDescription& rDesc,
if (pDoc->GetIDocumentUndoRedo().DoesUndo())
{
pDoc->GetIDocumentUndoRedo().EndUndo(UNDO_TOXCHANGE, NULL);
if (pNewTOX == NULL)
{
pDoc->GetIDocumentUndoRedo().DelAllUndoObj();
}
}
}
......
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