[Libreoffice-commits] core.git: sw/source

Michael Stahl mstahl at redhat.com
Tue Mar 6 12:00:15 UTC 2018


 sw/source/core/layout/findfrm.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit eef36faf5d8450f9ba5c905da8e87d31c2fa73d5
Author: Michael Stahl <mstahl at redhat.com>
Date:   Tue Mar 6 10:00:28 2018 +0100

    sw: convert checks about mbInfTab and cell parent to assert()
    
    Change-Id: Ia9e517936d546f60f76ae99062ff57a09209dc8a
    Reviewed-on: https://gerrit.libreoffice.org/50805
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Michael Stahl <mstahl at redhat.com>

diff --git a/sw/source/core/layout/findfrm.cxx b/sw/source/core/layout/findfrm.cxx
index 4f2453e09f93..60b37f363555 100644
--- a/sw/source/core/layout/findfrm.cxx
+++ b/sw/source/core/layout/findfrm.cxx
@@ -750,7 +750,7 @@ SwFrame *SwFrame::FindNext_()
         SwLayoutFrame *pUp = pThis->GetUpper();
         while (pUp && !pUp->IsCellFrame())
             pUp = pUp->GetUpper();
-        SAL_WARN_IF(!pUp, "sw.core", "Content in table but not in cell.");
+        assert(pUp && "Content flag says it's in table but it's not in cell.");
         SwFrame* pNxt = pUp ? static_cast<SwCellFrame*>(pUp)->GetFollowCell() : nullptr;
         if ( pNxt )
             pNxt = static_cast<SwCellFrame*>(pNxt)->ContainsContent();
@@ -1108,7 +1108,7 @@ SwFrame *SwFrame::FindPrev_()
             SwLayoutFrame *pUp = pThis->GetUpper();
             while (pUp && !pUp->IsCellFrame())
                 pUp = pUp->GetUpper();
-            SAL_WARN_IF(!pUp, "sw.core", "Content in table but not in cell.");
+            assert(pUp && "Content flag says it's in table but it's not in cell.");
             if (pUp && pUp->IsAnLower(pPrvCnt))
                 return pPrvCnt;
         }


More information about the Libreoffice-commits mailing list