On Wed Oct 25 18:35:41 2023 +0000, Yuxuan Shui wrote:
The deadlock is this: media_engine_Shutdown (holds `engine->cs`) -> session Shutdown -> samplegrabber media sink Shutdown (wants `grabber->cs`) vs sample_grabber_stream_timer_callback_Invoke (holds `grabber->cs`) -> media_engine_grabber_callback_OnProcessSample (wants `engine->cs`) I think we can make `engine->flags` atomic and don't try to acquire `enigne->cs` in case the engine is shutdown.
I think this can be part of !4133