From 3c230d608b766e573eeca66e203114b262478230 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Thu, 20 Aug 2020 12:56:36 +0100 Subject: rhbz#1870501 crash on reexport of odg MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit where SdrObjects in a list have no navigation position set a regression from 450cd772aa734cfcb989c8cedd3c0a454db74a34 Fix fdo#64512 Handle xml:id correctly on multi-image draw:frames this just reverts that and adds the test case that crashed Change-Id: I1a49dab9578699c42fe845e8ec42de40159dec3d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101074 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- sd/qa/unit/data/odg/rhbz1870501.odg | Bin 0 -> 403275 bytes sd/qa/unit/export-tests.cxx | 9 +++++++++ 2 files changed, 9 insertions(+) create mode 100644 sd/qa/unit/data/odg/rhbz1870501.odg (limited to 'sd') diff --git a/sd/qa/unit/data/odg/rhbz1870501.odg b/sd/qa/unit/data/odg/rhbz1870501.odg new file mode 100644 index 000000000000..cc4bcef193c2 Binary files /dev/null and b/sd/qa/unit/data/odg/rhbz1870501.odg differ diff --git a/sd/qa/unit/export-tests.cxx b/sd/qa/unit/export-tests.cxx index eb97da60fd1f..1acda7b2712f 100644 --- a/sd/qa/unit/export-tests.cxx +++ b/sd/qa/unit/export-tests.cxx @@ -81,6 +81,7 @@ public: void testSoftEdges(); void testShadowBlur(); void testTdf115753(); + void testRhbz1870501(); CPPUNIT_TEST_SUITE(SdExportTest); @@ -119,6 +120,7 @@ public: CPPUNIT_TEST(testSoftEdges); CPPUNIT_TEST(testShadowBlur); CPPUNIT_TEST(testTdf115753); + CPPUNIT_TEST(testRhbz1870501); CPPUNIT_TEST_SUITE_END(); @@ -1377,6 +1379,13 @@ void SdExportTest::testShadowBlur() xDocShRef->DoClose(); } +void SdExportTest::testRhbz1870501() +{ + //Without the fix in place, it would crash at export time + ::sd::DrawDocShellRef xDocShRef = loadURL( m_directories.getURLFromSrc("/sd/qa/unit/data/odg/rhbz1870501.odg"), ODG); + xDocShRef = saveAndReload( xDocShRef.get(), ODG ); +} + CPPUNIT_TEST_SUITE_REGISTRATION(SdExportTest); CPPUNIT_PLUGIN_IMPLEMENT(); -- cgit