include/dbaccess/AsynchronousLink.hxx        |    8 ++++++--
 sd/source/ui/unoidl/unomodel.cxx             |    6 +-----
 sd/source/ui/view/ToolBarManager.cxx         |    2 --
 sw/source/core/unocore/unocontentcontrol.cxx |    4 +---
 4 files changed, 8 insertions(+), 12 deletions(-)

New commits:
commit 7ccad64046ec871b8f4524497a703f9548ddbdfa
Author:     Noel Grandin <noel.gran...@collabora.co.uk>
AuthorDate: Mon Sep 30 12:56:46 2024 +0200
Commit:     Noel Grandin <noel.gran...@collabora.co.uk>
CommitDate: Tue Oct 1 11:16:12 2024 +0200

    loplugin:unusedfields
    
    Change-Id: I391bcae0c8491a17c57083e1375c8ed50d72ee9f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174295
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index b8f752199f4b..e680534fb46c 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -233,8 +233,6 @@ public:
 private:
     bool getFillStyleImpl(const uno::Reference<drawing::XDrawPage>& xDrawPage);
 private:
-    uno::Reference<drawing::XDrawPage> mxDrawPage;
-    uno::Reference<drawing::XDrawPage> mxMasterPage;
     uno::Reference<beans::XPropertySet> mxBackground;
     bool mbIsCustom;
     bool bHasBackground;
@@ -245,9 +243,7 @@ private:
 SlideBackgroundInfo::SlideBackgroundInfo(
         const uno::Reference<drawing::XDrawPage>& xDrawPage,
         const uno::Reference<drawing::XDrawPage>& xMasterPage)
-    : mxDrawPage(xDrawPage)
-    , mxMasterPage(xMasterPage)
-    , mbIsCustom(false)
+    : mbIsCustom(false)
     , bHasBackground(false)
     , mbIsSolidColor(false)
     , maFillStyle(drawing::FillStyle_NONE)
diff --git a/sd/source/ui/view/ToolBarManager.cxx 
b/sd/source/ui/view/ToolBarManager.cxx
index 89a8f9cfba61..dac9aa1d8c96 100644
--- a/sd/source/ui/view/ToolBarManager.cxx
+++ b/sd/source/ui/view/ToolBarManager.cxx
@@ -180,8 +180,6 @@ private:
         things easier and does not waste too much memory.
     */
     GroupedShellList maCurrentList;
-
-    std::shared_ptr<ViewShell> pCurrentActiveShell;
 };
 
 /** This class concentrates the knowledge about when to show what tool bars
diff --git a/sw/source/core/unocore/unocontentcontrol.cxx 
b/sw/source/core/unocore/unocontentcontrol.cxx
index 3328c5eafb73..5327a4d646da 100644
--- a/sw/source/core/unocore/unocontentcontrol.cxx
+++ b/sw/source/core/unocore/unocontentcontrol.cxx
@@ -187,7 +187,6 @@ public:
     sal_uInt32 m_nTabIndex;
     OUString m_aLock;
     OUString m_aMultiLine;
-    SwContentControlType m_iType;
 
     Impl(SwXContentControl& rThis, SwDoc& rDoc, SwContentControl* 
pContentControl,
          css::uno::Reference<SwXText> xParentText, std::unique_ptr<const 
TextRangeList_t> pPortions)
@@ -207,7 +206,6 @@ public:
         , m_bDropDown(false)
         , m_nId(0)
         , m_nTabIndex(0)
-        , m_iType(SwContentControlType::RICH_TEXT)
     {
         if (m_pContentControl)
         {
@@ -1346,7 +1344,7 @@ uno::Any SAL_CALL 
SwXContentControl::getPropertyValue(const OUString& rPropertyN
     {
         if (m_pImpl->m_bIsDescriptor)
         {
-            aRet <<= static_cast<sal_Int32>(m_pImpl->m_iType);
+            aRet <<= static_cast<sal_Int32>(SwContentControlType::RICH_TEXT);
         }
         else
         {
commit 9a2f11cc1fc9b0157e185b39abbd6a50c4cfc8cd
Author:     Noel Grandin <noelgran...@gmail.com>
AuthorDate: Mon Sep 30 19:35:01 2024 +0200
Commit:     Noel Grandin <noel.gran...@collabora.co.uk>
CommitDate: Tue Oct 1 11:16:00 2024 +0200

    cid#1607861 Data race condition
    
    Change-Id: Ib58f6613b98b2b778c9894359fe92b6fcf33298d
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174293
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/include/dbaccess/AsynchronousLink.hxx 
b/include/dbaccess/AsynchronousLink.hxx
index 22c40dc5b714..cd1af635c03a 100644
--- a/include/dbaccess/AsynchronousLink.hxx
+++ b/include/dbaccess/AsynchronousLink.hxx
@@ -38,7 +38,7 @@ namespace dbaui
     class OAsynchronousLink final
     {
         Link<void*,void>    m_aHandler;
-        std::mutex          m_aEventSafety;
+        mutable std::mutex  m_aEventSafety;
         std::mutex          m_aDestructionSafety;
         ImplSVEvent *       m_nEventId;
         DECL_LINK(OnAsyncCall, void*, void);
@@ -50,7 +50,11 @@ namespace dbaui
         OAsynchronousLink( const Link<void*,void>& _rHandler );
         ~OAsynchronousLink();
 
-        bool    IsRunning() const { return m_nEventId != nullptr; }
+        bool    IsRunning() const
+        {
+            std::unique_lock aEventGuard(m_aEventSafety);
+            return m_nEventId != nullptr;
+        }
 
         void Call( void* _pArgument = nullptr );
         void CancelCall();

Reply via email to