Kaydet (Commit) 2c3b5e06 authored tarafından Noel Grandin's avatar Noel Grandin

fix for crash in CppunitTest_services on windows

after
    commit 9cceba9a
    make DBG_TESTSOLARMUTEX available in assert builds

bt looks like:

 #0  0x00007faf569074fd in ImplDbgTestSolarMutex()
 #1  0x00007faf56904df9 in vcl::EventPoster::~EventPoster()
 #2  0x00007faf4392b452 in AutoRecovery::~AutoRecovery()
 #3  0x00007faf4392b589 in AutoRecovery::~AutoRecovery()
 #4  0x00007faf5d03dfc8 in __run_exit_handlers()

Change-Id: If72eece22db89b492d8e69d1abb496168e32cb9d
Reviewed-on: https://gerrit.libreoffice.org/58636
Tested-by: Jenkins
Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst 20d3c7a6
...@@ -391,7 +391,7 @@ private: ...@@ -391,7 +391,7 @@ private:
Timer m_aTimer; Timer m_aTimer;
/** @short make our dispatch asynchronous ... if required to do so! */ /** @short make our dispatch asynchronous ... if required to do so! */
vcl::EventPoster m_aAsyncDispatcher; std::unique_ptr<vcl::EventPoster> m_xAsyncDispatcher;
/** @see DispatchParams /** @see DispatchParams
*/ */
...@@ -1209,7 +1209,7 @@ AutoRecovery::AutoRecovery(const css::uno::Reference< css::uno::XComponentContex ...@@ -1209,7 +1209,7 @@ AutoRecovery::AutoRecovery(const css::uno::Reference< css::uno::XComponentContex
, m_nAutoSaveTimeIntervall (0 ) , m_nAutoSaveTimeIntervall (0 )
, m_eJob (AutoRecovery::E_NO_JOB ) , m_eJob (AutoRecovery::E_NO_JOB )
, m_aTimer ( "Auto save timer" ) , m_aTimer ( "Auto save timer" )
, m_aAsyncDispatcher ( LINK( this, AutoRecovery, implts_asyncDispatch ) ) , m_xAsyncDispatcher (new vcl::EventPoster( LINK( this, AutoRecovery, implts_asyncDispatch ) ))
, m_eTimerType (E_DONT_START_TIMER ) , m_eTimerType (E_DONT_START_TIMER )
, m_nIdPool (0 ) , m_nIdPool (0 )
, m_lListener (cppu::WeakComponentImplHelperBase::rBHelper.rMutex) , m_lListener (cppu::WeakComponentImplHelperBase::rBHelper.rMutex)
...@@ -1241,6 +1241,8 @@ AutoRecovery::~AutoRecovery() ...@@ -1241,6 +1241,8 @@ AutoRecovery::~AutoRecovery()
void AutoRecovery::disposing() void AutoRecovery::disposing()
{ {
implts_stopTimer(); implts_stopTimer();
SolarMutexGuard g;
m_xAsyncDispatcher.reset();
} }
Any SAL_CALL AutoRecovery::queryInterface( const css::uno::Type& _rType ) Any SAL_CALL AutoRecovery::queryInterface( const css::uno::Type& _rType )
...@@ -1335,7 +1337,7 @@ void SAL_CALL AutoRecovery::dispatch(const css::util::URL& ...@@ -1335,7 +1337,7 @@ void SAL_CALL AutoRecovery::dispatch(const css::util::URL&
} /* SAFE */ } /* SAFE */
if (bAsync) if (bAsync)
m_aAsyncDispatcher.Post(); m_xAsyncDispatcher->Post();
else else
implts_dispatch(aParams); implts_dispatch(aParams);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment