Module: wine Branch: master Commit: b89a01bff8326ee9b8f343b86d4c212286141624 URL: https://gitlab.winehq.org/wine/wine/-/commit/b89a01bff8326ee9b8f343b86d4c212... Author: Anton Baskanov <baskanov(a)gmail.com> Date: Sat Oct 29 18:28:25 2022 +0700 winegstreamer: Hold the streaming lock while destroying wg_transform. Otherwise, the streaming thread might try to access it while it's being destroyed. --- dlls/winegstreamer/quartz_transform.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dlls/winegstreamer/quartz_transform.c b/dlls/winegstreamer/quartz_transform.c index 6520f697ce4..ccdec9454a6 100644 --- a/dlls/winegstreamer/quartz_transform.c +++ b/dlls/winegstreamer/quartz_transform.c @@ -129,7 +129,9 @@ static HRESULT transform_cleanup_stream(struct strmbase_filter *iface) { IMemAllocator_Decommit(filter->source.pAllocator); + EnterCriticalSection(&filter->filter.stream_cs); wg_transform_destroy(filter->transform); + LeaveCriticalSection(&filter->filter.stream_cs); } return S_OK;