diff options
Diffstat (limited to 'forms/source/component/EventThread.cxx')
-rw-r--r-- | forms/source/component/EventThread.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/forms/source/component/EventThread.cxx b/forms/source/component/EventThread.cxx index 2d5336fe384b..62b0af091c8f 100644 --- a/forms/source/component/EventThread.cxx +++ b/forms/source/component/EventThread.cxx @@ -76,11 +76,11 @@ void OComponentEventThread::impl_clearEventQueue() void OComponentEventThread::disposing( const EventObject& evt ) { + std::unique_lock aGuard( m_aMutex ); + if( evt.Source != static_cast<XWeak*>(m_xComp.get()) ) return; - std::unique_lock aGuard( m_aMutex ); - // Remove EventListener Reference<XEventListener> xEvtLstnr = static_cast<XEventListener*>(this); m_xComp->removeEventListener( xEvtLstnr ); |