mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-02-04 06:08:26 +02:00
avcodec/h264: reset list_count too in case of error in ff_set_ref_count()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
7ee8a1c562
commit
98dcbb47fa
@ -3409,6 +3409,7 @@ int ff_set_ref_count(H264Context *h)
|
|||||||
if (ref_count[0]-1 > max[0] || ref_count[1]-1 > max[1]){
|
if (ref_count[0]-1 > max[0] || ref_count[1]-1 > max[1]){
|
||||||
av_log(h->avctx, AV_LOG_ERROR, "reference overflow %u > %u or %u > %u\n", ref_count[0]-1, max[0], ref_count[1]-1, max[1]);
|
av_log(h->avctx, AV_LOG_ERROR, "reference overflow %u > %u or %u > %u\n", ref_count[0]-1, max[0], ref_count[1]-1, max[1]);
|
||||||
h->ref_count[0] = h->ref_count[1] = 0;
|
h->ref_count[0] = h->ref_count[1] = 0;
|
||||||
|
h->list_count = 0;
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user