diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2021-09-07 21:10:07 +0200 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2021-09-07 23:16:15 +0200 |
commit | e662e835c208481c909d8caa34fc66b6fadda3c0 (patch) | |
tree | 32521a2ec07ffc8419bbd48106425decf7e26f3c /framework | |
parent | 975c73fe13e743ecd922a93be190476cf250d9ba (diff) |
Guard Orcus detection shortcut
So that its policy matches the other places in this function
Change-Id: I309441f63cf82bbae2b19c7de588d4228b988bad
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121764
Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'framework')
-rw-r--r-- | framework/source/loadenv/loadenv.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/framework/source/loadenv/loadenv.cxx b/framework/source/loadenv/loadenv.cxx index cd83d9403748..a4b7e6557004 100644 --- a/framework/source/loadenv/loadenv.cxx +++ b/framework/source/loadenv/loadenv.cxx @@ -745,6 +745,9 @@ void LoadEnv::impl_detectTypeAndFilter() if (queryOrcusTypeAndFilter(lDescriptor, sType, sFilter) && !sType.isEmpty() && !sFilter.isEmpty()) { + // SAFE -> + osl::MutexGuard aWriteLock(m_mutex); + // Orcus type detected. Skip the normal type detection process. m_lMediaDescriptor << lDescriptor; m_lMediaDescriptor[utl::MediaDescriptor::PROP_TYPENAME()] <<= sType; @@ -752,6 +755,7 @@ void LoadEnv::impl_detectTypeAndFilter() m_lMediaDescriptor[utl::MediaDescriptor::PROP_FILTERPROVIDER()] <<= OUString("orcus"); m_lMediaDescriptor[utl::MediaDescriptor::PROP_DOCUMENTSERVICE()] <<= OUString("com.sun.star.sheet.SpreadsheetDocument"); return; + // <- SAFE } css::uno::Reference< css::document::XTypeDetection > xDetect( |