mirror of https://git.ffmpeg.org/ffmpeg.git
ffplay: remove redundant !codec check
Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
parent
fdb933444a
commit
fec39d99d6
3
ffplay.c
3
ffplay.c
|
@ -2307,8 +2307,7 @@ static int stream_component_open(VideoState *is, int stream_index)
|
||||||
opts = filter_codec_opts(codec_opts, avctx->codec_id, ic, ic->streams[stream_index], codec);
|
opts = filter_codec_opts(codec_opts, avctx->codec_id, ic, ic->streams[stream_index], codec);
|
||||||
if (!av_dict_get(opts, "threads", NULL, 0))
|
if (!av_dict_get(opts, "threads", NULL, 0))
|
||||||
av_dict_set(&opts, "threads", "auto", 0);
|
av_dict_set(&opts, "threads", "auto", 0);
|
||||||
if (!codec ||
|
if (avcodec_open2(avctx, codec, &opts) < 0)
|
||||||
avcodec_open2(avctx, codec, &opts) < 0)
|
|
||||||
return -1;
|
return -1;
|
||||||
if ((t = av_dict_get(opts, "", NULL, AV_DICT_IGNORE_SUFFIX))) {
|
if ((t = av_dict_get(opts, "", NULL, AV_DICT_IGNORE_SUFFIX))) {
|
||||||
av_log(NULL, AV_LOG_ERROR, "Option %s not found.\n", t->key);
|
av_log(NULL, AV_LOG_ERROR, "Option %s not found.\n", t->key);
|
||||||
|
|
Loading…
Reference in New Issue