summaryrefslogtreecommitdiff
path: root/fpicker/source/office
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-02-24 15:02:01 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-02-27 10:20:32 +0000
commitedf8047e854f78d5b90a601eda598d19a40301bf (patch)
tree5407d2b6a29f4a7785d7d6a3811aa423775253a1 /fpicker/source/office
parent09ada9cf6e15f3a735d2c94737b045c5e0f001ef (diff)
osl::Mutex->std::mutex in FileViewContentEnumerator
Change-Id: Ib9f0b7ba39f5acbfbdbd664f74a4a91f645c8192 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147862 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'fpicker/source/office')
-rw-r--r--fpicker/source/office/contentenumeration.cxx16
-rw-r--r--fpicker/source/office/contentenumeration.hxx3
2 files changed, 10 insertions, 9 deletions
diff --git a/fpicker/source/office/contentenumeration.cxx b/fpicker/source/office/contentenumeration.cxx
index fbf310a0dc91..5eb12feeef2e 100644
--- a/fpicker/source/office/contentenumeration.cxx
+++ b/fpicker/source/office/contentenumeration.cxx
@@ -92,7 +92,7 @@ namespace svt
void FileViewContentEnumerator::cancel()
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_bCancelled = true;
m_pResultHandler = nullptr;
m_aFolder.aContent = ::ucbhelper::Content();
@@ -105,7 +105,7 @@ namespace svt
const css::uno::Sequence< OUString >& rDenyList )
{
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_aFolder = _rFolder;
m_pResultHandler = nullptr;
m_rDenyList = rDenyList;
@@ -117,7 +117,7 @@ namespace svt
void FileViewContentEnumerator::enumerateFolderContent(
const FolderDescriptor& _rFolder, IEnumerationResultHandler* _pResultHandler )
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_aFolder = _rFolder;
m_pResultHandler = _pResultHandler;
@@ -157,7 +157,7 @@ namespace svt
{
FolderDescriptor aFolder;
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
aFolder = m_aFolder;
xEnvironment = m_xCommandEnv;
}
@@ -165,7 +165,7 @@ namespace svt
{
aFolder.aContent = ::ucbhelper::Content( aFolder.sURL, xEnvironment, comphelper::getProcessComponentContext() );
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
m_aFolder.aContent = aFolder.aContent;
}
}
@@ -215,7 +215,7 @@ namespace svt
// check for restrictions
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
if ( /* m_rDenyList.hasElements() && */ URLOnDenyList ( sRealURL ) )
continue;
}
@@ -268,7 +268,7 @@ namespace svt
}
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
bCancelled = m_bCancelled;
}
}
@@ -287,7 +287,7 @@ namespace svt
IEnumerationResultHandler* pHandler = nullptr;
{
- ::osl::MutexGuard aGuard( m_aMutex );
+ std::unique_lock aGuard( m_aMutex );
pHandler = m_pResultHandler;
if ( m_bCancelled )
return EnumerationResult::ERROR;
diff --git a/fpicker/source/office/contentenumeration.hxx b/fpicker/source/office/contentenumeration.hxx
index b1c07afcf1c4..d15db4d7a55f 100644
--- a/fpicker/source/office/contentenumeration.hxx
+++ b/fpicker/source/office/contentenumeration.hxx
@@ -22,6 +22,7 @@
#include <sal/config.h>
#include <memory>
+#include <mutex>
#include <com/sun/star/ucb/XCommandEnvironment.hpp>
#include <salhelper/thread.hxx>
@@ -163,7 +164,7 @@ namespace svt
ContentData& m_rContent;
::osl::Mutex& m_rContentMutex;
- mutable ::osl::Mutex m_aMutex;
+ mutable std::mutex m_aMutex;
FolderDescriptor m_aFolder;
css::uno::Reference< css::ucb::XCommandEnvironment >