mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2026-06-16 04:32:47 +02:00
h264: do not let invalid values in h->ref_count on ff_h264_decode_ref_pic_list_reordering() errors.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 2428b53f6d)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
committed by
Michael Niedermayer
parent
8e6173c76a
commit
d1a5b53ede
+3
-1
@@ -3940,8 +3940,10 @@ static int decode_slice_header(H264Context *h, H264Context *h0){
|
||||
fill_default_ref_list(h);
|
||||
}
|
||||
|
||||
if(h->slice_type_nos!=FF_I_TYPE && decode_ref_pic_list_reordering(h) < 0)
|
||||
if(h->slice_type_nos!=FF_I_TYPE && decode_ref_pic_list_reordering(h) < 0) {
|
||||
h->ref_count[1]= h->ref_count[0]= 0;
|
||||
return -1;
|
||||
}
|
||||
|
||||
if(h->slice_type_nos!=FF_I_TYPE){
|
||||
s->last_picture_ptr= &h->ref_list[0][0];
|
||||
|
||||
Reference in New Issue
Block a user