summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/core/data/rtf/README3
-rw-r--r--sw/qa/core/data/rtf/fail/.gitignore0
-rw-r--r--sw/qa/core/data/rtf/indeterminate/.gitignore0
-rw-r--r--sw/qa/core/data/rtf/pass/abi3241.rtf9
-rw-r--r--sw/qa/core/filters-test.cxx5
-rw-r--r--sw/source/core/txtnode/ndtxt.cxx2
6 files changed, 18 insertions, 1 deletions
diff --git a/sw/qa/core/data/rtf/README b/sw/qa/core/data/rtf/README
new file mode 100644
index 000000000000..cd109d3fa13a
--- /dev/null
+++ b/sw/qa/core/data/rtf/README
@@ -0,0 +1,3 @@
+Put RTF crash-test files here only in case the crash is in Writer core. If the
+crash is in the RTF import itself, use the writerfilter RTF testsuite instead,
+that's faster.
diff --git a/sw/qa/core/data/rtf/fail/.gitignore b/sw/qa/core/data/rtf/fail/.gitignore
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/sw/qa/core/data/rtf/fail/.gitignore
diff --git a/sw/qa/core/data/rtf/indeterminate/.gitignore b/sw/qa/core/data/rtf/indeterminate/.gitignore
new file mode 100644
index 000000000000..e69de29bb2d1
--- /dev/null
+++ b/sw/qa/core/data/rtf/indeterminate/.gitignore
diff --git a/sw/qa/core/data/rtf/pass/abi3241.rtf b/sw/qa/core/data/rtf/pass/abi3241.rtf
new file mode 100644
index 000000000000..5bfec3d0ce92
--- /dev/null
+++ b/sw/qa/core/data/rtf/pass/abi3241.rtf
@@ -0,0 +1,9 @@
+{\rtf1
+{\stylesheet
+{\sa120 Normal;}
+{\s6\sbasedon0 \snext0 heading 6;}
+}
+\pard\plain \s6
+If more than one reaction channel is to be considered, use the keyword
+\par
+}
diff --git a/sw/qa/core/filters-test.cxx b/sw/qa/core/filters-test.cxx
index 26fcd58049af..e5ba36b31c90 100644
--- a/sw/qa/core/filters-test.cxx
+++ b/sw/qa/core/filters-test.cxx
@@ -112,6 +112,11 @@ void SwFiltersTest::testCVEs()
getURLFromSrc("/sw/qa/core/data/ooxml/"),
OUString(),
SFX_FILTER_STARONEFILTER);
+
+ testDir(OUString("Rich Text Format"),
+ getURLFromSrc("/sw/qa/core/data/rtf/"),
+ OUString(),
+ SFX_FILTER_STARONEFILTER);
}
void SwFiltersTest::setUp()
diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx
index 07f36ef82d06..8d4cdaf2f831 100644
--- a/sw/source/core/txtnode/ndtxt.cxx
+++ b/sw/source/core/txtnode/ndtxt.cxx
@@ -1067,7 +1067,7 @@ void SwTxtNode::_ChgTxtCollUpdateNum( const SwTxtFmtColl *pOldColl,
const int nNewLevel = pNewColl && pNewColl->IsAssignedToListLevelOfOutlineStyle() ?
pNewColl->GetAssignedOutlineStyleLevel() : MAXLEVEL;
- if ( MAXLEVEL != nNewLevel )
+ if ( MAXLEVEL != nNewLevel && -1 != nNewLevel )
{
SetAttrListLevel(nNewLevel);
}