diff options
-rw-r--r-- | lotuswordpro/source/filter/lwptablelayout.cxx | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lotuswordpro/source/filter/lwptablelayout.cxx b/lotuswordpro/source/filter/lwptablelayout.cxx index 379c44b34c13..ff4b7f65a6f9 100644 --- a/lotuswordpro/source/filter/lwptablelayout.cxx +++ b/lotuswordpro/source/filter/lwptablelayout.cxx @@ -543,8 +543,13 @@ OUString LwpTableLayout::GetColumnWidth(sal_uInt16 nCol) */ void LwpTableLayout::RegisterColumns() { - LwpTable * pTable = GetTable(); - LwpSuperTableLayout * pSuper = GetSuperTableLayout(); + LwpTable* pTable = GetTable(); + if (!pTable) + throw std::range_error("corrupt LwpTableLayout"); + + LwpSuperTableLayout* pSuper = GetSuperTableLayout(); + if (!pSuper) + throw std::range_error("corrupt LwpTableLayout"); sal_uInt16 nCols = m_nCols; @@ -556,9 +561,6 @@ void LwpTableLayout::RegisterColumns() m_aColumns[i] = nullptr; } - if (!pTable) - throw std::range_error("corrupt LwpTableLayout"); - double dDefaultColumn = pTable->GetWidth(); sal_uInt16 nJustifiableColumn = nCols; |