diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-03-28 19:03:33 +0400 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-03-28 20:29:26 +0400 |
commit | 2b4543ff696893e925a32eac5de2259dff243696 (patch) | |
tree | e3894fef1864b0b06c4bcdcd4b676c80119ea37d /cmdutils.c | |
parent | 92005c26360abf9fe2f3cdb3af8bceb285a0aaeb (diff) |
cmdutils/filter_codec_opts: do not discard all options for CODEC_ID_NONE
This fixes cases where the codec is detect later than the stream creation
No testcase with unmodified source known
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'cmdutils.c')
-rw-r--r-- | cmdutils.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmdutils.c b/cmdutils.c index dc9bd2cc00..be3189ae24 100644 --- a/cmdutils.c +++ b/cmdutils.c @@ -1942,7 +1942,8 @@ AVDictionary *filter_codec_opts(AVDictionary *opts, enum AVCodecID codec_id, } if (av_opt_find(&cc, t->key, NULL, flags, AV_OPT_SEARCH_FAKE_OBJ) || - (codec && codec->priv_class && + !codec || + (codec->priv_class && av_opt_find(&codec->priv_class, t->key, NULL, flags, AV_OPT_SEARCH_FAKE_OBJ))) av_dict_set(&ret, t->key, t->value, 0); |