[FFmpeg-devel] [PATCH 5/5] tgq: use bytestream2_get_bytes_left()

Paul B Mahol onemda at gmail.com
Wed Mar 21 01:10:22 CET 2012


Signed-off-by: Paul B Mahol <onemda at gmail.com>
---
 libavcodec/eatgq.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavcodec/eatgq.c b/libavcodec/eatgq.c
index 5eb9ca3..756b7ed 100644
--- a/libavcodec/eatgq.c
+++ b/libavcodec/eatgq.c
@@ -150,7 +150,7 @@ static void tgq_decode_mb(TgqContext *s, int mb_y, int mb_x){
     mode = bytestream2_get_byte(&s->gb);
     if (mode>12) {
         GetBitContext gb;
-        init_get_bits(&gb, s->gb.buffer, FFMIN(s->gb.buffer_end - s->gb.buffer, mode) * 8);
+        init_get_bits(&gb, s->gb.buffer, FFMIN(bytestream2_get_bytes_left(&s->gb), mode) * 8);
         for(i=0; i<6; i++)
             tgq_decode_block(s, s->block[i], &gb);
         tgq_idct_put_mb(s, s->block, mb_x, mb_y);
-- 
1.7.7



More information about the ffmpeg-devel mailing list