diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-10-21 14:36:51 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-10-22 08:01:19 +0200 |
commit | 19bc8856c4b5444f80375919c2aed00c7de53a28 (patch) | |
tree | 94256a4db6d6feb4f148e405f1a540c9b0db3869 /vcl/source/text/TextLayoutCache.cxx | |
parent | 76319347a83aecee7a423a614d67287182b31b00 (diff) |
move vcl::DeleteOnDeinit to tools
so we can fix a shutdown use-after-free in sot.
Change-Id: I32f83bd94627d72d7bee7ea2ebd6ab77a7f78435
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175335
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source/text/TextLayoutCache.cxx')
-rw-r--r-- | vcl/source/text/TextLayoutCache.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vcl/source/text/TextLayoutCache.cxx b/vcl/source/text/TextLayoutCache.cxx index 414ab29f895a..3e3571dfc861 100644 --- a/vcl/source/text/TextLayoutCache.cxx +++ b/vcl/source/text/TextLayoutCache.cxx @@ -24,7 +24,7 @@ #include <o3tl/hash_combine.hxx> #include <o3tl/lru_map.hxx> #include <unotools/configmgr.hxx> -#include <vcl/lazydelete.hxx> +#include <tools/lazydelete.hxx> #include <officecfg/Office/Common.hxx> namespace vcl::text @@ -55,7 +55,7 @@ std::shared_ptr<const TextLayoutCache> TextLayoutCache::Create(OUString const& r typedef o3tl::lru_map<OUString, std::shared_ptr<const TextLayoutCache>, FirstCharsStringHash, FastStringCompareEqual, TextLayoutCacheCost> Cache; - static vcl::DeleteOnDeinit<Cache> cache( + static tools::DeleteOnDeinit<Cache> cache( !comphelper::IsFuzzing() ? officecfg::Office::Common::Cache::Font::TextRunsCacheSize::get() : 100); if (Cache* map = cache.get()) |