mf: Clear queued topologies on session shutdown.

Programs might expect objects inside the queued toplogy to be freed,
before they eventually call release on the session itself.

This fixes reference leaks to stored objects in queued topology nodes,
even when IMFMediaSession_Shutdown() was called.

Signed-off-by: Bernhard Kölbl <besentv@gmail.com>
This commit is contained in:
Bernhard Kölbl 2023-05-30 23:25:27 +02:00 committed by Alexandre Julliard
parent c43a4aee77
commit bea37208fe

View file

@ -2225,6 +2225,7 @@ static HRESULT WINAPI mfsession_Shutdown(IMFMediaSession *iface)
IMFPresentationClock_Release(session->clock);
session->clock = NULL;
session_clear_presentation(session);
session_clear_queued_topologies(session);
session_submit_simple_command(session, SESSION_CMD_SHUTDOWN);
}
LeaveCriticalSection(&session->cs);