summaryrefslogtreecommitdiff
path: root/writerfilter/source
diff options
context:
space:
mode:
Diffstat (limited to 'writerfilter/source')
-rw-r--r--writerfilter/source/rtftok/rtfdocumentimpl.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
index fe35afe1d372..adf0a80c6956 100644
--- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx
+++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx
@@ -1123,8 +1123,10 @@ RTFError RTFDocumentImpl::resolveChars(char ch)
if (!bSkipped)
{
// note: apparently \'0d\'0a is interpreted as 2 breaks, not 1
- if (m_aStates.top().eDestination != Destination::DOCCOMM
- && (ch == '\r' || ch == '\n'))
+ if ((ch == '\r' || ch == '\n')
+ && m_aStates.top().eDestination != Destination::DOCCOMM
+ && m_aStates.top().eDestination != Destination::LEVELNUMBERS
+ && m_aStates.top().eDestination != Destination::LEVELTEXT)
{
checkUnicode(/*bUnicode =*/ false, /*bHex =*/ true);
dispatchSymbol(RTF_PAR);