summaryrefslogtreecommitdiff
path: root/bridges
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2021-07-18 14:25:02 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-07-18 20:46:47 +0200
commit4ab57949a2cbaacba33375ea33dc896205eac6c9 (patch)
tree5b2379d9e8baf4aa5d88c576bcad123b61d5335f /bridges
parent6db41dd2649a9ddaf32fc779bed07dc7d61c1154 (diff)
osl::Mutex->std::mutex in VtableFactory
Change-Id: Ie973ef2923c1c725ee740000ebd1eacf671a5bfb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119139 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'bridges')
-rw-r--r--bridges/inc/vtablefactory.hxx4
-rw-r--r--bridges/source/cpp_uno/shared/vtablefactory.cxx4
2 files changed, 4 insertions, 4 deletions
diff --git a/bridges/inc/vtablefactory.hxx b/bridges/inc/vtablefactory.hxx
index c169f7c0bfd0..9afcb837099d 100644
--- a/bridges/inc/vtablefactory.hxx
+++ b/bridges/inc/vtablefactory.hxx
@@ -19,13 +19,13 @@
#pragma once
-#include <osl/mutex.hxx>
#include <rtl/alloc.h>
#include <rtl/ustring.hxx>
#include <sal/types.h>
#include <typelib/typedescription.hxx>
#include <memory>
+#include <mutex>
#include <unordered_map>
/*See: http://people.redhat.com/drepper/selinux-mem.html*/
@@ -210,7 +210,7 @@ private:
typedef std::unordered_map< OUString, Vtables > Map;
- osl::Mutex m_mutex;
+ std::mutex m_mutex;
Map m_map;
rtl_arena_type * m_arena;
diff --git a/bridges/source/cpp_uno/shared/vtablefactory.cxx b/bridges/source/cpp_uno/shared/vtablefactory.cxx
index 9d4c5d31dd3f..a74d75ed1f28 100644
--- a/bridges/source/cpp_uno/shared/vtablefactory.cxx
+++ b/bridges/source/cpp_uno/shared/vtablefactory.cxx
@@ -214,7 +214,7 @@ VtableFactory::VtableFactory(): m_arena(
VtableFactory::~VtableFactory() {
{
- osl::MutexGuard guard(m_mutex);
+ std::lock_guard guard(m_mutex);
for (const auto& rEntry : m_map) {
for (sal_Int32 j = 0; j < rEntry.second.count; ++j) {
freeBlock(rEntry.second.blocks[j]);
@@ -228,7 +228,7 @@ const VtableFactory::Vtables& VtableFactory::getVtables(
typelib_InterfaceTypeDescription * type)
{
OUString name(type->aBase.pTypeName);
- osl::MutexGuard guard(m_mutex);
+ std::lock_guard guard(m_mutex);
Map::iterator i(m_map.find(name));
if (i == m_map.end()) {
GuardedBlocks blocks(*this);