[FFmpeg-cvslog] h264: Decode short VUI without error
Michael Niedermayer
git at videolan.org
Fri Dec 23 06:48:36 CET 2011
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Dec 23 05:58:32 2011 +0100| [ae7a6441df26b5dd921af95677ec5e6dd35dc970] | committer: Michael Niedermayer
h264: Decode short VUI without error
Fixes 47j9R7PXBep.mov
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ae7a6441df26b5dd921af95677ec5e6dd35dc970
---
libavcodec/h264_ps.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/libavcodec/h264_ps.c b/libavcodec/h264_ps.c
index f879576..5c21d80 100644
--- a/libavcodec/h264_ps.c
+++ b/libavcodec/h264_ps.c
@@ -229,7 +229,8 @@ static inline int decode_vui_parameters(H264Context *h, SPS *sps){
if(sps->nal_hrd_parameters_present_flag || sps->vcl_hrd_parameters_present_flag)
get_bits1(&s->gb); /* low_delay_hrd_flag */
sps->pic_struct_present_flag = get_bits1(&s->gb);
-
+ if(!get_bits_left(&s->gb))
+ return 0;
sps->bitstream_restriction_flag = get_bits1(&s->gb);
if(sps->bitstream_restriction_flag){
get_bits1(&s->gb); /* motion_vectors_over_pic_boundaries_flag */
More information about the ffmpeg-cvslog
mailing list