avcodec/tak_parser: fix parsing of streams with bunch of small frames at end

Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
Paul B Mahol
2016-04-18 23:37:41 +02:00
parent f25367f4b4
commit 13406b6124
+1 -1
View File
@@ -59,7 +59,7 @@ static int tak_parse(AVCodecParserContext *s, AVCodecContext *avctx,
while (buf_size || t->index + needed <= pc->index) {
if (buf_size && t->index + TAK_MAX_FRAME_HEADER_BYTES > pc->index) {
int tmp_buf_size = FFMIN(2 * TAK_MAX_FRAME_HEADER_BYTES,
int tmp_buf_size = FFMIN(TAK_MAX_FRAME_HEADER_BYTES,
buf_size);
const uint8_t *tmp_buf = buf;