sw/qa/core/exportdata/rtf/pass/fdo70624.odt |binary
 sw/source/filter/ww8/rtfexport.cxx          |    6 +++---
 2 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 8591de009a4fed6264f236bbcafb2accae70754f
Author: Miklos Vajna <vmik...@collabora.co.uk>
Date:   Mon Dec 30 14:14:38 2013 +0100

    Related: fdo#70624 RTF export: fix crash when header contains a page break
    
    I don't even try to imagine how such a thing can be created and/or how
    layout should handle that; but it turns out that the ODT bugdoc indeed
    contains a fo:break-before="page" in the header, and we at least should
    not crash on it.
    
    Fix the problem by simple moving the init of m_pSections before the
    WritePageDescTable() call.
    
    Change-Id: If414e2f6184c58fcfd8b761d3b43fa0fc22d3903

diff --git a/sw/qa/core/exportdata/rtf/pass/fdo70624.odt 
b/sw/qa/core/exportdata/rtf/pass/fdo70624.odt
new file mode 100644
index 0000000..1b177e8
Binary files /dev/null and b/sw/qa/core/exportdata/rtf/pass/fdo70624.odt differ
diff --git a/sw/source/filter/ww8/rtfexport.cxx 
b/sw/source/filter/ww8/rtfexport.cxx
index 89539ea..5113f93 100644
--- a/sw/source/filter/ww8/rtfexport.cxx
+++ b/sw/source/filter/ww8/rtfexport.cxx
@@ -525,6 +525,9 @@ void RtfExport::ExportDocument_Impl()
     // Record changes?
     if (nsRedlineMode_t::REDLINE_ON & mnRedlineMode)
         Strm() << OOO_STRING_SVTOOLS_RTF_REVISIONS;
+    // Init sections
+    m_pSections = new MSWordSections( *this );
+
     // Page description
     WritePageDescTable();
 
@@ -693,9 +696,6 @@ void RtfExport::ExportDocument_Impl()
 
     Strm() << SAL_NEWLINE_STRING;
 
-    // Init sections
-    m_pSections = new MSWordSections( *this );
-
     WriteMainText();
 
     Strm() << '}';
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to