diff options
author | Luboš Luňák <l.lunak@collabora.com> | 2018-10-01 14:26:57 +0200 |
---|---|---|
committer | Luboš Luňák <l.lunak@collabora.com> | 2018-10-10 13:01:59 +0200 |
commit | 79449d73900d7a9bf061244d76f5f8eecc441198 (patch) | |
tree | e85f9bc29941cbf5e5ccb858ee4703ae67d00810 /sc/inc/lookupcache.hxx | |
parent | b1721b04d8a921a69230927cd7995d8c5d8f5fe2 (diff) |
make VLOOKUP in Calc thread-safe
There is mutex protection needed for accessing the same SvtBroadcaster
when calling StartListeningArea(). Also some of the memory management
and caching needed fixing.
Change-Id: Ia57ed85286cf195521719cfd3b320f73a6342bb1
Reviewed-on: https://gerrit.libreoffice.org/61187
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
Diffstat (limited to 'sc/inc/lookupcache.hxx')
-rw-r--r-- | sc/inc/lookupcache.hxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sc/inc/lookupcache.hxx b/sc/inc/lookupcache.hxx index fa55c2bcbced..15ec15f086b1 100644 --- a/sc/inc/lookupcache.hxx +++ b/sc/inc/lookupcache.hxx @@ -23,6 +23,7 @@ #include "address.hxx" #include <svl/listener.hxx> +#include <memory> #include <unordered_map> class ScDocument; @@ -189,6 +190,13 @@ private: }; +// Struct because including lookupcache.hxx in document.hxx isn't wanted. +struct ScLookupCacheMap +{ + std::unordered_map< ScRange, std::unique_ptr<ScLookupCache>, ScLookupCache::Hash > aCacheMap; +}; + + #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |