diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-12-10 09:49:07 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-12-10 09:50:13 +0000 |
commit | 4bc26e006dd4bde95eef706de43228679a41c4f7 (patch) | |
tree | 4d9c53d4e5523fcc3dc262b86388d2ac8dd78100 /lotuswordpro | |
parent | 8edd7897ac1309ee636c7b7e21bc157440c10caf (diff) |
guard against missing table layout
Change-Id: I4bc7a7283f63124ccb50957ea64791644e01e267
(cherry picked from commit 0c876483d278e3e5ba43e9eaf40ca713b6099703)
Reviewed-on: https://gerrit.libreoffice.org/20576
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'lotuswordpro')
-rw-r--r-- | lotuswordpro/source/filter/lwpcelllayout.cxx | 3 | ||||
-rw-r--r-- | lotuswordpro/source/filter/lwprowlayout.cxx | 5 |
2 files changed, 7 insertions, 1 deletions
diff --git a/lotuswordpro/source/filter/lwpcelllayout.cxx b/lotuswordpro/source/filter/lwpcelllayout.cxx index abe2c0297717..3848cb6a9f90 100644 --- a/lotuswordpro/source/filter/lwpcelllayout.cxx +++ b/lotuswordpro/source/filter/lwpcelllayout.cxx @@ -696,6 +696,9 @@ void LwpConnectedCellLayout::SetCellMap() { // this function is called from LwpTableLayout, so it can't be NULL LwpTableLayout * pTableLayout = GetTableLayout(); + if (!pTableLayout) + return; + sal_uInt16 nRowSpan = m_nRealrowspan; for (sal_uInt16 iLoop = 0; iLoop < nRowSpan; iLoop ++) diff --git a/lotuswordpro/source/filter/lwprowlayout.cxx b/lotuswordpro/source/filter/lwprowlayout.cxx index 507a8490fcff..906c09cdb052 100644 --- a/lotuswordpro/source/filter/lwprowlayout.cxx +++ b/lotuswordpro/source/filter/lwprowlayout.cxx @@ -363,11 +363,14 @@ sal_uInt16 LwpRowLayout::GetCurMaxSpannedRows(sal_uInt8 nStartCol,sal_uInt8 nEnd */ void LwpRowLayout::ConvertCommonRow(XFTable* pXFTable,sal_uInt8 nStartCol,sal_uInt8 nEndCol) { + LwpTableLayout* pTableLayout = GetParentTableLayout(); + if (!pTableLayout) + return; + XFRow* pRow = new XFRow; pRow->SetStyleName(m_StyleName); XFCell * pCell = nullptr; - LwpTableLayout* pTableLayout = GetParentTableLayout(); LwpTable* pTable = pTableLayout->GetTable(); sal_uInt8 nCellStartCol,nCellEndCol; |