1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-08 13:22:53 +02:00

avcodec/put_bits: Assert buf_ptr in flush_put_bits()

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 3ef5de0f19)

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Michael Niedermayer 2016-01-18 17:13:55 +01:00
parent eb0872335f
commit f6755e5e19

View File

@ -105,7 +105,7 @@ static inline void flush_put_bits(PutBitContext *s)
s->bit_buf <<= s->bit_left;
#endif
while (s->bit_left < 32) {
/* XXX: should test end of buffer */
av_assert0(s->buf_ptr < s->buf_end);
#ifdef BITSTREAM_WRITER_LE
*s->buf_ptr++ = s->bit_buf;
s->bit_buf >>= 8;