cid#1555162 Data race condition

Change-Id: I0f1aa14732d6fe32ac6875e29cb678cb0b2d2872
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174427
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Noel Grandin
2024-10-03 18:43:47 +02:00
committed by Noel Grandin
parent 259624bc68
commit 95faca7cf8
+6 -2
View File
@@ -34,14 +34,18 @@
class VCLXPointer final : public cppu::WeakImplHelper<
css::awt::XPointer, css::lang::XServiceInfo>
{
std::mutex maMutex;
mutable std::mutex maMutex;
PointerStyle maPointer;
public:
VCLXPointer();
virtual ~VCLXPointer() override;
PointerStyle GetPointer() const { return maPointer; }
PointerStyle GetPointer() const
{
std::scoped_lock aGuard( maMutex );
return maPointer;
}
// css::awt::XPointer
void SAL_CALL setType( sal_Int32 nType ) override;