提交 b6f505ce 编写于 作者: L Limin Wang

avcodec/mpeg12dec: Fix uninitialized data in fate-sub-cc-scte20

The issue is introduced in a705bcd7, please tested with below command line:
make V=1 fate-sub-cc-scte20 TARGET_EXEC="valgrind --error-exitcode=1"
Reported-by: NMartin Storsjö <martin@martin.st>
Reviewed-by: NMartin Storsjö <martin@martin.st>
Signed-off-by: NLimin Wang <lance.lmwang@gmail.com>
上级 5005b41a
......@@ -2276,6 +2276,8 @@ static int mpeg_decode_a53_cc(AVCodecContext *avctx,
if (ret >= 0) {
uint8_t field, cc1, cc2;
uint8_t *cap = s1->a53_buf_ref->data;
memset(s1->a53_buf_ref->data + old_size, 0, cc_count * 3);
for (i = 0; i < cc_count && get_bits_left(&gb) >= 26; i++) {
skip_bits(&gb, 2); // priority
field = get_bits(&gb, 2);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册