diff --git a/sw/qa/extras/odftok/data/empty-svg-family-name.odt b/sw/qa/extras/odftok/data/empty-svg-family-name.odt new file mode 100644 index 000000000000..b4b5516e92fc Binary files /dev/null and b/sw/qa/extras/odftok/data/empty-svg-family-name.odt differ diff --git a/sw/qa/extras/odftok/odftok.cxx b/sw/qa/extras/odftok/odftok.cxx index efbadb3beb64..bb62a18c8808 100644 --- a/sw/qa/extras/odftok/odftok.cxx +++ b/sw/qa/extras/odftok/odftok.cxx @@ -33,10 +33,12 @@ class Test : public SwModelTestBase { public: void testHello(); + void testEmptySvgFamilyName(); CPPUNIT_TEST_SUITE(Test); #if !defined(MACOSX) && !defined(WNT) CPPUNIT_TEST(testHello); + CPPUNIT_TEST(testEmptySvgFamilyName); #endif CPPUNIT_TEST_SUITE_END(); @@ -56,6 +58,12 @@ void Test::testHello() CPPUNIT_ASSERT_EQUAL(12, getLength()); } +void Test::testEmptySvgFamilyName() +{ + // .odt import did crash on the empty font list (which I think is valid according SVG spec) + load( "empty-svg-family-name.odt" ); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Test); CPPUNIT_PLUGIN_IMPLEMENT();