|
|
|
@ -2626,7 +2626,6 @@ static int stream_component_open(VideoState *is, int stream_index) |
|
|
|
|
const AVCodec *codec; |
|
|
|
|
const char *forced_codec_name = NULL; |
|
|
|
|
AVDictionary *opts = NULL; |
|
|
|
|
const AVDictionaryEntry *t = NULL; |
|
|
|
|
int sample_rate; |
|
|
|
|
AVChannelLayout ch_layout = { 0 }; |
|
|
|
|
int ret = 0; |
|
|
|
@ -2694,11 +2693,9 @@ static int stream_component_open(VideoState *is, int stream_index) |
|
|
|
|
if ((ret = avcodec_open2(avctx, codec, &opts)) < 0) { |
|
|
|
|
goto fail; |
|
|
|
|
} |
|
|
|
|
if ((t = av_dict_iterate(opts, NULL))) { |
|
|
|
|
av_log(NULL, AV_LOG_ERROR, "Option %s not found.\n", t->key); |
|
|
|
|
ret = AVERROR_OPTION_NOT_FOUND; |
|
|
|
|
ret = check_avoptions(opts); |
|
|
|
|
if (ret < 0) |
|
|
|
|
goto fail; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
is->eof = 0; |
|
|
|
|
ic->streams[stream_index]->discard = AVDISCARD_DEFAULT; |
|
|
|
@ -2862,11 +2859,9 @@ static int read_thread(void *arg) |
|
|
|
|
if (scan_all_pmts_set) |
|
|
|
|
av_dict_set(&format_opts, "scan_all_pmts", NULL, AV_DICT_MATCH_CASE); |
|
|
|
|
|
|
|
|
|
if ((t = av_dict_iterate(format_opts, NULL))) { |
|
|
|
|
av_log(NULL, AV_LOG_ERROR, "Option %s not found.\n", t->key); |
|
|
|
|
ret = AVERROR_OPTION_NOT_FOUND; |
|
|
|
|
ret = check_avoptions(format_opts); |
|
|
|
|
if (ret < 0) |
|
|
|
|
goto fail; |
|
|
|
|
} |
|
|
|
|
is->ic = ic; |
|
|
|
|
|
|
|
|
|
if (genpts) |
|
|
|
|