cid#1660229 Double lock

OInterfaceContainerHelper4<ListenerT>::disposeAndClear will leave
rGuard locked when it finishes

Change-Id: Ifd01c7ed8d70e6332c1ac4ddc9b6b0315610d996
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188976
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
This commit is contained in:
Caolán McNamara
2025-08-06 09:34:06 +02:00
parent 368cd2678f
commit fc6a456590
+4 -9
View File
@@ -187,21 +187,16 @@ void SlideShowView::disposingImpl(std::unique_lock<std::mutex>& rGuard)
}
rGuard.lock();
}
assert(rGuard.owns_lock());
if (maPaintListeners.getLength(rGuard))
{
maPaintListeners.disposeAndClear( rGuard, evt );
rGuard.lock();
}
assert(rGuard.owns_lock());
if (maMouseListeners.getLength(rGuard))
{
maMouseListeners.disposeAndClear( rGuard, evt );
rGuard.lock();
}
assert(rGuard.owns_lock());
if (maMouseMotionListeners.getLength(rGuard))
{
maMouseMotionListeners.disposeAndClear( rGuard, evt );
rGuard.lock();
}
assert(rGuard.owns_lock());
}
void SlideShowView::paint( const awt::PaintEvent& e )