sw/qa/extras/layout/data/forcepoint79-1.doc |binary sw/qa/extras/layout/layout.cxx | 3 +++ sw/source/core/layout/findfrm.cxx | 10 ++++------ 3 files changed, 7 insertions(+), 6 deletions(-)
New commits: commit 453e6fb7c1827d317dc775df32a6cf91b2bb5a67 Author: Caolán McNamara <[email protected]> AuthorDate: Thu Apr 18 11:29:37 2019 +0100 Commit: Caolán McNamara <[email protected]> CommitDate: Thu Apr 18 17:13:24 2019 +0200 forcepoint#79 FindStartEndOfRowSpanCell returning null Change-Id: I85f5b17b7dc2d3c4dfef92f64451fab451f58112 Reviewed-on: https://gerrit.libreoffice.org/70927 Tested-by: Jenkins Reviewed-by: Caolán McNamara <[email protected]> Tested-by: Caolán McNamara <[email protected]> diff --git a/sw/qa/extras/layout/data/forcepoint79-1.doc b/sw/qa/extras/layout/data/forcepoint79-1.doc new file mode 100644 index 000000000000..ba53db79f278 Binary files /dev/null and b/sw/qa/extras/layout/data/forcepoint79-1.doc differ diff --git a/sw/qa/extras/layout/layout.cxx b/sw/qa/extras/layout/layout.cxx index e44acc8ba1c0..91705c8e18d9 100644 --- a/sw/qa/extras/layout/layout.cxx +++ b/sw/qa/extras/layout/layout.cxx @@ -2564,6 +2564,9 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testForcepoint75) //just care it doesn't crash/assert CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testForcepoint76) { createDoc("forcepoint76-1.rtf"); } +//just care it doesn't crash/assert +CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testForcepoint79) { createDoc("forcepoint79-1.doc"); } + CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testTdf118058) { SwDoc* pDoc = createDoc("tdf118058.fodt"); diff --git a/sw/source/core/layout/findfrm.cxx b/sw/source/core/layout/findfrm.cxx index 7a411d549ba6..1e98e7549947 100644 --- a/sw/source/core/layout/findfrm.cxx +++ b/sw/source/core/layout/findfrm.cxx @@ -1668,8 +1668,6 @@ SwCellFrame* SwCellFrame::GetPreviousCell() const // --> NEW TABLES const SwCellFrame& SwCellFrame::FindStartEndOfRowSpanCell( bool bStart ) const { - const SwCellFrame* pRet = nullptr; - const SwTabFrame* pTableFrame = dynamic_cast<const SwTabFrame*>(GetUpper()->GetUpper()); if ( !bStart && pTableFrame && pTableFrame->IsFollow() && pTableFrame->IsInHeadline( *this ) ) @@ -1726,17 +1724,17 @@ const SwCellFrame& SwCellFrame::FindStartEndOfRowSpanCell( bool bStart ) const if ( pMasterTable == pTableFrame ) { - pRet = pMasterCell; - break; + return *pMasterCell; } } } } - assert(pRet && "SwCellFrame::FindStartRowSpanCell: No result"); + SAL_WARN("sw.core", "SwCellFrame::FindStartRowSpanCell: No result"); - return *pRet; + return *this; } + // <-- NEW TABLES const SwRowFrame* SwFrame::IsInSplitTableRow() const _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
