summaryrefslogtreecommitdiff
path: root/writerfilter
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2013-07-10 12:41:57 +0200
committerMichael Stahl <mstahl@redhat.com>2013-07-10 12:44:34 +0200
commitb3944f124ab3dc87332796a46387f837ad29e8d5 (patch)
tree19b4b594cd24d49b631b749083597b47857980a0 /writerfilter
parent1c90902cbccd4e4f5946dfc454da351c33c24f71 (diff)
rhbz#960019 : RTF import: handle extra groups in listoverride entry
This crashed because for a single listoverride entry 2 SPRMs were sent to the domain-mapper, and the second one was empty. Change-Id: Ic41ffd8bd4edcff065f49ecef3464efedd909d63
Diffstat (limited to 'writerfilter')
-rw-r--r--writerfilter/source/rtftok/rtfdocumentimpl.cxx14
1 files changed, 12 insertions, 2 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index 38dd6dc1c6bb..18b3f96173ba 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -4563,8 +4563,18 @@ int RTFDocumentImpl::popState()
// list override table
case DESTINATION_LISTOVERRIDEENTRY:
{
- RTFValue::Pointer_t pValue(new RTFValue(aState.aTableAttributes, aState.aTableSprms));
- m_aListTableSprms.set(NS_ooxml::LN_CT_Numbering_num, pValue, false);
+ if (m_aStates.top().nDestinationState == DESTINATION_LISTOVERRIDEENTRY)
+ { // copy properties upwards so upper popState inserts it
+ m_aStates.top().aTableAttributes = aState.aTableAttributes;
+ m_aStates.top().aTableSprms = aState.aTableSprms;
+ }
+ else
+ {
+ RTFValue::Pointer_t pValue(new RTFValue(
+ aState.aTableAttributes, aState.aTableSprms));
+ m_aListTableSprms.set(NS_ooxml::LN_CT_Numbering_num,
+ pValue, false);
+ }
}
break;
case DESTINATION_LEVELTEXT: