player: shutdown all clients before actual uninit

This seems safer. It might be possible that commands sent by the clients
could recreate e.g. audio or video outputs.
This commit is contained in:
wm4 2014-10-19 22:34:00 +02:00
parent 2cd25891b6
commit 2f559ac70b
1 changed files with 2 additions and 2 deletions

View File

@ -119,6 +119,8 @@ static void shutdown_clients(struct MPContext *mpctx)
void mp_destroy(struct MPContext *mpctx)
{
shutdown_clients(mpctx);
uninit_audio_out(mpctx);
uninit_video_out(mpctx);
@ -129,8 +131,6 @@ void mp_destroy(struct MPContext *mpctx)
mpctx->encode_lavc_ctx = NULL;
shutdown_clients(mpctx);
#if !defined(__MINGW32__)
mp_uninit_ipc(mpctx->ipc_ctx);
mpctx->ipc_ctx = NULL;