coverity#704967 Unchecked dynamic_cast

Change-Id: I2aa69b8876dce21c362d54053072cc0cfcd3dc8d
This commit is contained in:
Caolán McNamara 2014-05-28 12:03:10 +01:00
parent bfbcdc9ceb
commit 4259f9b381

View file

@ -1780,14 +1780,14 @@ sal_Bool SwXTextTableCursor::splitRange(sal_Int16 Count, sal_Bool Horizontal)
// hier muessen die Actions aufgehoben werden
UnoActionRemoveContext aRemoveContext(pUnoCrsr->GetDoc());
}
SwUnoTableCrsr* pTblCrsr = dynamic_cast<SwUnoTableCrsr*>(pUnoCrsr);
pTblCrsr->MakeBoxSels();
SwUnoTableCrsr& rTblCrsr = dynamic_cast<SwUnoTableCrsr&>(*pUnoCrsr);
rTblCrsr.MakeBoxSels();
{
UnoActionContext aContext(pUnoCrsr->GetDoc());
bRet = pTblCrsr->GetDoc()->SplitTbl(
pTblCrsr->GetSelectedBoxes(), !Horizontal, Count);
bRet = rTblCrsr.GetDoc()->SplitTbl(
rTblCrsr.GetSelectedBoxes(), !Horizontal, Count);
}
pTblCrsr->MakeBoxSels();
rTblCrsr.MakeBoxSels();
}
return bRet;
}