mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-12 02:04:58 +00:00
avcodec/parser: assert that the codec id is not NONE in av_parser_parse2()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
b6b4b0a65e
commit
9f03b85045
@ -141,6 +141,8 @@ int av_parser_parse2(AVCodecParserContext *s, AVCodecContext *avctx,
|
||||
int index, i;
|
||||
uint8_t dummy_buf[AV_INPUT_BUFFER_PADDING_SIZE];
|
||||
|
||||
av_assert1(avctx->codec_id != AV_CODEC_ID_NONE);
|
||||
|
||||
/* Parsers only work for the specified codec ids. */
|
||||
av_assert1(avctx->codec_id == s->parser->codec_ids[0] ||
|
||||
avctx->codec_id == s->parser->codec_ids[1] ||
|
||||
|
Loading…
Reference in New Issue
Block a user