]> git.sesse.net Git - ffmpeg/commitdiff
Fix the check for missing references in ff_er_frame_end() for H264.
authorLaurent Aimar <fenrir@videolan.org>
Sat, 1 Oct 2011 22:38:31 +0000 (00:38 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Sun, 2 Oct 2011 01:24:17 +0000 (03:24 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/error_resilience.c

index 3fb95ead88f8436704a97dae231e4bd0e1cd2f59..cf967bf2159eb7fb34c42847335a92e5c604cd41 100644 (file)
@@ -660,7 +660,7 @@ static int is_intra_more_likely(MpegEncContext *s){
 
     if(s->codec_id == CODEC_ID_H264){
         H264Context *h= (void*)s;
-        if (h->ref_count[0] <= 0 || !h->ref_list[0][0].f.data[0])
+        if (h->list_count <= 0 || h->ref_count[0] <= 0 || !h->ref_list[0][0].f.data[0])
             return 1;
     }