[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - lotuswordpro/source
Caolán McNamara
caolanm at redhat.com
Sun Dec 13 03:54:49 PST 2015
lotuswordpro/source/filter/xfilter/xftable.cxx | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
New commits:
commit 27f138b27b14827485e587cf924a227b8aabe91f
Author: Caolán McNamara <caolanm at redhat.com>
Date: Sun Dec 13 11:53:43 2015 +0000
guard against missing header rows
Change-Id: Iaa28ef00572eb9c4ba3a6d8ae0c668b7b0132f56
(cherry picked from commit 2487ba80581d8b0f50be40a26255789e1a050e95)
diff --git a/lotuswordpro/source/filter/xfilter/xftable.cxx b/lotuswordpro/source/filter/xfilter/xftable.cxx
index 9a96db8..d139a85 100644
--- a/lotuswordpro/source/filter/xfilter/xftable.cxx
+++ b/lotuswordpro/source/filter/xfilter/xftable.cxx
@@ -104,9 +104,11 @@ void XFTable::AddRow(XFRow *pRow)
m_aRows[row] = pRow;
}
-void XFTable::AddHeaderRow(XFRow *pRow)
+void XFTable::AddHeaderRow(XFRow *pRow)
{
- if( !pRow )
+ if( !pRow)
+ return;
+ if (!m_aHeaderRows.is())
return;
m_aHeaderRows->Add(pRow);
}
@@ -207,7 +209,7 @@ void XFTable::ToXml(IXFStream *pStrm)
}
}
- if( m_aHeaderRows->GetCount()>0 )
+ if (m_aHeaderRows.is() && m_aHeaderRows->GetCount()>0)
{
pStrm->StartElement( "table:table-header-rows" );
m_aHeaderRows->ToXml(pStrm);
More information about the Libreoffice-commits
mailing list