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

Eike Rathke erack at redhat.com
Wed Aug 27 05:05:39 PDT 2014


 sc/source/core/data/table3.cxx |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit b77bf9759a74454391fa5d2f4a6ec4594d6d3e89
Author: Eike Rathke <erack at redhat.com>
Date:   Wed Aug 27 14:01:31 2014 +0200

    assert on first use
    
    Change-Id: I63a513406dbd90746bcad9da88945f49d2b51cc5

diff --git a/sc/source/core/data/table3.cxx b/sc/source/core/data/table3.cxx
index 2874cd6..3fe5f7e 100644
--- a/sc/source/core/data/table3.cxx
+++ b/sc/source/core/data/table3.cxx
@@ -932,11 +932,13 @@ void ScTable::SortReorderByRow(
 
             std::vector<PatternSpan>::iterator it = aSpans.begin(), itEnd = aSpans.end();
             for (; it != itEnd; ++it)
+            {
+                assert(it->mpPattern); // should never be NULL.
                 pDocument->GetPool()->Put(*it->mpPattern);
+            }
 
             for (it = aSpans.begin(); it != itEnd; ++it)
             {
-                assert(it->mpPattern); // should never be NULL.
                 aCol[nThisCol].SetPatternArea(it->mnRow1, it->mnRow2, *it->mpPattern, true);
                 pDocument->GetPool()->Remove(*it->mpPattern);
             }


More information about the Libreoffice-commits mailing list