[Libreoffice-commits] core.git: Branch 'libreoffice-4-4' - sc/source

Eike Rathke erack at redhat.com
Tue Aug 18 04:41:21 PDT 2015


 sc/source/core/data/document.cxx |    8 ++++++++
 1 file changed, 8 insertions(+)

New commits:
commit 78c988f3ebbcd84832ca671dfed16ce1664f3bfe
Author: Eike Rathke <erack at redhat.com>
Date:   Tue Aug 18 11:33:44 2015 +0200

    Resolves: tdf#92749 invalidate lookup caches after initial hard recalc
    
    ... because the caches are not setup as listeners during when the
    document's hard recalc state is active.
    
    Change-Id: Ie7ec84ee64d046e3e55ce26b92824e94a2f660e9
    (cherry picked from commit f7e493229bd949066b4d8984dce7678b8687d1ae)
    Reviewed-on: https://gerrit.libreoffice.org/17832
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sc/source/core/data/document.cxx b/sc/source/core/data/document.cxx
index 59fef65..8c26dd8 100644
--- a/sc/source/core/data/document.cxx
+++ b/sc/source/core/data/document.cxx
@@ -3752,6 +3752,14 @@ void ScDocument::CalcAll()
         if (*it)
             (*it)->CalcAll();
     ClearFormulaTree();
+
+    // In hard recalc state caches were not added as listeners, invalidate them
+    // so the next non-CalcAll() normal lookup will not be presented with
+    // outdated data.
+    /* TODO: come up with more detailed hard recalc states so we can
+     * differentiate between hard recalc after load and others. */
+    if (GetHardRecalcState())
+        ClearLookupCaches();
 }
 
 void ScDocument::CompileAll()


More information about the Libreoffice-commits mailing list