diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2021-12-18 18:57:12 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-12-20 08:34:04 +0100 |
commit | 7e44d8d78a3c58a5468c4c3331992a0c472560c6 (patch) | |
tree | 875d4efe0965a0ea453894ac80bc910d4f4ce63f /framework/source | |
parent | 7fe0a4cddf23f0c15e95ff59e658ee3bbe11db51 (diff) |
osl::Mutex->std::mutex in HelpOnStartup
Change-Id: I3133ab5e0f0af40c7570856c216f3921576818af
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127103
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'framework/source')
-rw-r--r-- | framework/source/jobs/helponstartup.cxx | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/framework/source/jobs/helponstartup.cxx b/framework/source/jobs/helponstartup.cxx index 41c6c3dc3e1e..968a3aa10577 100644 --- a/framework/source/jobs/helponstartup.cxx +++ b/framework/source/jobs/helponstartup.cxx @@ -133,7 +133,7 @@ css::uno::Any SAL_CALL HelpOnStartup::execute(const css::uno::Sequence< css::bea void SAL_CALL HelpOnStartup::disposing(const css::lang::EventObject& aEvent) { - osl::MutexGuard g(m_mutex); + std::unique_lock g(m_mutex); if (aEvent.Source == m_xModuleManager) m_xModuleManager.clear(); else if (aEvent.Source == m_xDesktop) @@ -174,9 +174,9 @@ OUString HelpOnStartup::its_getModuleIdFromEnv(const css::uno::Sequence< css::be // OK - now we are sure this document is a top level document. // Classify it. // SAFE -> - osl::ClearableMutexGuard aLock(m_mutex); + std::unique_lock aLock(m_mutex); css::uno::Reference< css::frame::XModuleManager2 > xModuleManager = m_xModuleManager; - aLock.clear(); + aLock.unlock(); // <- SAFE OUString sModuleId; @@ -195,9 +195,9 @@ OUString HelpOnStartup::its_getModuleIdFromEnv(const css::uno::Sequence< css::be OUString HelpOnStartup::its_getCurrentHelpURL() { // SAFE -> - osl::ClearableMutexGuard aLock(m_mutex); + std::unique_lock aLock(m_mutex); css::uno::Reference< css::frame::XDesktop2 > xDesktop = m_xDesktop; - aLock.clear(); + aLock.unlock(); // <- SAFE if (!xDesktop.is()) @@ -239,11 +239,11 @@ bool HelpOnStartup::its_isHelpUrlADefaultOne(std::u16string_view sHelpURL) return false; // SAFE -> - osl::ClearableMutexGuard aLock(m_mutex); + std::unique_lock aLock(m_mutex); css::uno::Reference< css::container::XNameAccess > xConfig = m_xConfig; OUString sLocale = m_sLocale; OUString sSystem = m_sSystem; - aLock.clear(); + aLock.unlock(); // <- SAFE if (!xConfig.is()) @@ -282,11 +282,11 @@ bool HelpOnStartup::its_isHelpUrlADefaultOne(std::u16string_view sHelpURL) OUString HelpOnStartup::its_checkIfHelpEnabledAndGetURL(const OUString& sModule) { // SAFE -> - osl::ClearableMutexGuard aLock(m_mutex); + std::unique_lock aLock(m_mutex); css::uno::Reference< css::container::XNameAccess > xConfig = m_xConfig; OUString sLocale = m_sLocale; OUString sSystem = m_sSystem; - aLock.clear(); + aLock.unlock(); // <- SAFE OUString sHelpURL; |