diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2024-10-02 19:23:16 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-10-03 10:39:50 +0200 |
commit | 87519013cb9ed1eae27f799a1a35c8a3cd0e3dd7 (patch) | |
tree | c01ffbc143afdd77aa15f719b5d0773e16da2226 /ucb | |
parent | 12e7a664f8e0accea5b52d9537d8133a5e7a2c2c (diff) |
cid#1606693 Data race condition
Change-Id: I107174d36f2bfa0cdcb7017838b1b4404179fb0c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174407
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
Diffstat (limited to 'ucb')
-rw-r--r-- | ucb/source/core/ucbstore.cxx | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/ucb/source/core/ucbstore.cxx b/ucb/source/core/ucbstore.cxx index 7190906b8147..6cc7ee759ab8 100644 --- a/ucb/source/core/ucbstore.cxx +++ b/ucb/source/core/ucbstore.cxx @@ -170,12 +170,9 @@ UcbStore::createPropertySetRegistry( const OUString& ) // The URL parameter is ignored by this interface implementation. It always // uses the configuration server as storage medium. + std::unique_lock aGuard( m_aMutex ); if ( !m_xTheRegistry.is() ) - { - std::unique_lock aGuard( m_aMutex ); - if ( !m_xTheRegistry.is() ) - m_xTheRegistry = new PropertySetRegistry( m_xContext, m_aInitArgs ); - } + m_xTheRegistry = new PropertySetRegistry( m_xContext, m_aInitArgs ); return m_xTheRegistry; } |