ucb/source/core/ucbstore.cxx |    7 +++----
 ucb/source/core/ucbstore.hxx |    7 +++----
 2 files changed, 6 insertions(+), 8 deletions(-)

New commits:
commit 42ac3410c0642c5c00023c3d6fb2df093af5fe94
Author:     Noel Grandin <noelgran...@gmail.com>
AuthorDate: Mon Dec 27 09:49:15 2021 +0200
Commit:     Noel Grandin <noel.gran...@collabora.co.uk>
CommitDate: Mon Dec 27 13:28:56 2021 +0100

    use comphelper::WeakComponentImplHelper in UcbStore
    
    Change-Id: I0246fe4c93208e87bddcf08ce6423d1e8f7505d2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127552
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/ucb/source/core/ucbstore.cxx b/ucb/source/core/ucbstore.cxx
index a0eece461c7d..fcdc0138ede0 100644
--- a/ucb/source/core/ucbstore.cxx
+++ b/ucb/source/core/ucbstore.cxx
@@ -128,8 +128,7 @@ public:
 
 
 UcbStore::UcbStore( const Reference< XComponentContext >& xContext )
-: UcbStore_Base(m_aMutex),
-  m_xContext( xContext )
+: m_xContext( xContext )
 {
 }
 
@@ -174,7 +173,7 @@ UcbStore::createPropertySetRegistry( const OUString& )
 
     if ( !m_xTheRegistry.is() )
     {
-        osl::Guard< osl::Mutex > aGuard( m_aMutex );
+        std::unique_lock aGuard( m_aMutex );
         if ( !m_xTheRegistry.is() )
             m_xTheRegistry = new PropertySetRegistry( m_xContext, m_aInitArgs 
);
     }
@@ -189,7 +188,7 @@ UcbStore::createPropertySetRegistry( const OUString& )
 // virtual
 void SAL_CALL UcbStore::initialize( const Sequence< Any >& aArguments )
 {
-    osl::Guard< osl::Mutex > aGuard( m_aMutex );
+    std::unique_lock aGuard( m_aMutex );
     m_aInitArgs = aArguments;
 }
 
diff --git a/ucb/source/core/ucbstore.hxx b/ucb/source/core/ucbstore.hxx
index de9488b28c05..0042bbafadc2 100644
--- a/ucb/source/core/ucbstore.hxx
+++ b/ucb/source/core/ucbstore.hxx
@@ -35,17 +35,16 @@
 #include <com/sun/star/lang/XInitialization.hpp>
 #include <comphelper/interfacecontainer3.hxx>
 #include <comphelper/multiinterfacecontainer3.hxx>
-#include <cppuhelper/compbase.hxx>
-#include <cppuhelper/basemutex.hxx>
+#include <comphelper/compbase.hxx>
 #include <unordered_map>
 
 
-using UcbStore_Base = cppu::WeakComponentImplHelper <
+using UcbStore_Base = comphelper::WeakComponentImplHelper <
                         css::lang::XServiceInfo,
                         css::ucb::XPropertySetRegistryFactory,
                         css::lang::XInitialization >;
 
-class UcbStore : public cppu::BaseMutex, public UcbStore_Base
+class UcbStore : public UcbStore_Base
 {
     css::uno::Reference< css::uno::XComponentContext >    m_xContext;
     css::uno::Sequence< css::uno::Any >                   m_aInitArgs;

Reply via email to