1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-19 05:49:09 +02:00

avcodec/h264: reset the counts in the correct context

Fixes null pointer dereference

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2015-04-08 13:38:55 +02:00
parent 7d5908d5c8
commit 8be177e048

View File

@ -1678,7 +1678,7 @@ again:
if (err < 0 || err == SLICE_SKIPED) {
if (err < 0)
av_log(h->avctx, AV_LOG_ERROR, "decode_slice_header error\n");
h->ref_count[0] = h->ref_count[1] = h->list_count = 0;
hx->ref_count[0] = hx->ref_count[1] = hx->list_count = 0;
} else if (err == SLICE_SINGLETHREAD) {
if (context_count > 1) {
ret = ff_h264_execute_decode_slices(h, context_count - 1);