player: deselect video track if initialization fails

This didn't have any consequences, other than suddenly reinitializing
video when it works again (such as with EDL timeline mixing video and
audio-only files).
This commit is contained in:
wm4 2013-11-19 22:16:56 +01:00
parent 16233bc546
commit 904ae96795
1 changed files with 1 additions and 0 deletions

View File

@ -165,6 +165,7 @@ err_out:
no_video: no_video:
uninit_player(mpctx, INITIALIZED_VCODEC | (opts->force_vo ? 0 : INITIALIZED_VO)); uninit_player(mpctx, INITIALIZED_VCODEC | (opts->force_vo ? 0 : INITIALIZED_VO));
cleanup_demux_stream(mpctx, STREAM_VIDEO); cleanup_demux_stream(mpctx, STREAM_VIDEO);
mpctx->current_track[STREAM_VIDEO] = NULL;
handle_force_window(mpctx, true); handle_force_window(mpctx, true);
MP_INFO(mpctx, "Video: no video\n"); MP_INFO(mpctx, "Video: no video\n");
return 0; return 0;