coverity#1373351 make SetTabRows the same as SetTabCols

Change-Id: I9cfe2f3ec96ee72ff2e7657661a003086d301db6
This commit is contained in:
Caolán McNamara
2016-09-23 09:04:25 +01:00
parent 78cc97405b
commit 5840a28fd4

View File

@@ -2767,11 +2767,17 @@ void SwDoc::SetTabCols( const SwTabCols &rNew, bool bCurRowOnly,
void SwDoc::SetTabRows( const SwTabCols &rNew, bool bCurColOnly,
const SwCellFrame* pBoxFrame )
{
SwTabFrame *pTab;
SwTabFrame *pTab = nullptr;
OSL_ENSURE( pBoxFrame, "SetTabRows called without pBoxFrame" );
pTab = const_cast<SwFrame*>(static_cast<SwFrame const *>(pBoxFrame))->ImplFindTabFrame();
if( pBoxFrame )
{
pTab = const_cast<SwFrame*>(static_cast<SwFrame const *>(pBoxFrame))->ImplFindTabFrame();
}
else
{
OSL_ENSURE( false, "must specify pBoxFrame" );
return ;
}
// If the Table is still using relative values (USHRT_MAX)
// we need to switch to absolute ones.