vlc | branch: master | Martin Storsjö <[email protected]> | Mon Mar 18 21:13:58 2013 +0200| [567597b43238a9092409118636352bd434d142a6] | committer: Martin Storsjö
h264_nal: Fix a boundary check in the H264 bitstream conversion routine Signed-off-by: Martin Storsjö <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=567597b43238a9092409118636352bd434d142a6 --- modules/codec/h264_nal.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/codec/h264_nal.h b/modules/codec/h264_nal.h index e0b6c98..ed9f6ae 100644 --- a/modules/codec/h264_nal.h +++ b/modules/codec/h264_nal.h @@ -114,7 +114,7 @@ static void convert_h264_to_annexb( uint8_t *p_buf, uint32_t i_len, p_buf[i] = 0; } p_buf[i_nal_size - 1] = 1; - if( nal_len > INT_MAX || nal_len > (unsigned int) i_len ) + if( nal_len > INT_MAX || nal_len + i_nal_size > (unsigned int) i_len ) break; p_buf += nal_len + i_nal_size; i_len -= nal_len + i_nal_size; _______________________________________________ vlc-commits mailing list [email protected] http://mailman.videolan.org/listinfo/vlc-commits
