[Libreoffice-commits] core.git: Branch 'distro/lhm/libreoffice-6-1+backports' - sw/source

Michael Stahl (via logerrit) logerrit at kemper.freedesktop.org
Sat Jun 29 00:50:06 UTC 2019


 sw/source/core/text/porrst.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 13eb1e3501faa32733668873f4aae36f2012e670
Author:     Michael Stahl <Michael.Stahl at cib.de>
AuthorDate: Wed Jun 26 19:13:37 2019 +0200
Commit:     Thorsten Behrens <Thorsten.Behrens at CIB.de>
CommitDate: Sat Jun 29 02:49:26 2019 +0200

    tdf#125751 sw: don't start recursive layout in SwTextFrame::EmptyHeight()
    
    Not sure if this has anything to do with the bug, but i noticed it while
    debugging...
    
    This is the only place that calls GetCurrFrame() *during* formatting,
    so make sure we don't do stupid recursive things.
    
    (regression from 56b2cf0c10d9caa01ebae1d80465e342d046a85c)
    
    Change-Id: Icd05f8d634bc9de4d5d16824d30075397e6c9960
    Reviewed-on: https://gerrit.libreoffice.org/74750
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <Michael.Stahl at cib.de>
    (cherry picked from commit 7a05458d39da2f4755cb6e190dce338198655137)
    Reviewed-on: https://gerrit.libreoffice.org/74787
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>
    (cherry picked from commit 91f86a51ed6f01e9c75999e8c1a42eaa47ff3ccb)
    Reviewed-on: https://gerrit.libreoffice.org/74844
    Reviewed-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
    Tested-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>

diff --git a/sw/source/core/text/porrst.cxx b/sw/source/core/text/porrst.cxx
index 727e0319a730..b959a4c3ba6e 100644
--- a/sw/source/core/text/porrst.cxx
+++ b/sw/source/core/text/porrst.cxx
@@ -211,7 +211,8 @@ SwTwips SwTextFrame::EmptyHeight() const
         SwViewShell *pSh = getRootFrame()->GetCurrShell();
         if ( dynamic_cast<const SwCursorShell*>( pSh ) !=  nullptr ) {
             SwCursorShell *pCrSh = static_cast<SwCursorShell*>(pSh);
-            SwContentFrame *pCurrFrame=pCrSh->GetCurrFrame();
+            // this is called during formatting so avoid recursive layout
+            SwContentFrame const*const pCurrFrame = pCrSh->GetCurrFrame(false);
             if (pCurrFrame==static_cast<SwContentFrame const *>(this)) {
                 // do nothing
             } else {


More information about the Libreoffice-commits mailing list