From facd4bb410ce6b5f6d74f836affc7553babb05cf Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 2 Oct 2013 23:00:09 +0200 Subject: [PATCH] rhbz#1001768: avoid deadlock in OAccessibleContextHelper::disposing() De facto this class is locked by SolarMutex, which is what the OExternalLockGuard actually locks; do not lock m_Mutex because it may cause deadlock. Change-Id: I88b226d73dbef9a5803347b0ac3191bec2ba4515 (cherry picked from commit 4100e3b6204fc304cc7b60b9d7ff2af75118b805) Reviewed-on: https://gerrit.libreoffice.org/6114 Tested-by: Michael Meeks Reviewed-by: Michael Meeks --- comphelper/source/misc/accessiblecontexthelper.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/comphelper/source/misc/accessiblecontexthelper.cxx b/comphelper/source/misc/accessiblecontexthelper.cxx index b3169fd..bb9047d 100644 --- a/comphelper/source/misc/accessiblecontexthelper.cxx +++ b/comphelper/source/misc/accessiblecontexthelper.cxx @@ -123,7 +123,9 @@ namespace comphelper //--------------------------------------------------------------------- void SAL_CALL OAccessibleContextHelper::disposing() { - ::osl::ClearableMutexGuard aGuard( GetMutex() ); + // rhbz#1001768: de facto this class is locked by SolarMutex; + // do not lock m_Mutex because it may cause deadlock + OMutexGuard aGuard( getExternalLock() ); if ( m_pImpl->getClientId( ) ) { -- 1.8.3.1