[FFmpeg-cvslog] avcodec/h264_parse: Clear ref_list[1] if only [0] is used
Michael Niedermayer
git at videolan.org
Fri Feb 8 13:21:04 EET 2019
ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Fri Feb 8 11:04:54 2019 +0100| [7f8bfbee36638f3bcacea8a6af5eece8878833ed] | committer: Michael Niedermayer
avcodec/h264_parse: Clear ref_list[1] if only [0] is used
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=7f8bfbee36638f3bcacea8a6af5eece8878833ed
---
libavcodec/h264_parse.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/libavcodec/h264_parse.c b/libavcodec/h264_parse.c
index a42cc299ff..a075443d17 100644
--- a/libavcodec/h264_parse.c
+++ b/libavcodec/h264_parse.c
@@ -253,6 +253,10 @@ int ff_h264_parse_ref_count(int *plist_count, int ref_count[2],
ref_count[0] = ref_count[1] = 0;
*plist_count = 0;
goto fail;
+ } else if (ref_count[1] - 1 > max[1]) {
+ av_log(logctx, AV_LOG_DEBUG, "reference overflow %u > %u \n",
+ ref_count[1] - 1, max[1]);
+ ref_count[1] = 0;
}
} else {
More information about the ffmpeg-cvslog
mailing list