aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2015-09-03 09:40:49 +0000
committerPaul B Mahol <onemda@gmail.com>2015-09-03 09:47:44 +0000
commit9136e65c405bcabf33e524ea79edf2a07831a7c3 (patch)
treeed360a2d467c3092bd549c76298ebac7efa57342
parent4cad4bd4ca6add29562efcd0fb447c1973a0e1ce (diff)
downloadffmpeg-9136e65c405bcabf33e524ea79edf2a07831a7c3.tar.gz
avcodec/fraps: use init_get_bits8()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
-rw-r--r--libavcodec/fraps.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/fraps.c b/libavcodec/fraps.c
index 8dcd0ae29c..2d4d5c48c4 100644
--- a/libavcodec/fraps.c
+++ b/libavcodec/fraps.c
@@ -105,7 +105,9 @@ static int fraps2_decode_plane(FrapsContext *s, uint8_t *dst, int stride, int w,
s->bdsp.bswap_buf((uint32_t *) s->tmpbuf,
(const uint32_t *) src, size >> 2);
- init_get_bits(&gb, s->tmpbuf, size * 8);
+ if ((ret = init_get_bits8(&gb, s->tmpbuf, size)) < 0)
+ return ret;
+
for (j = 0; j < h; j++) {
for (i = 0; i < w*step; i += step) {
dst[i] = get_vlc2(&gb, vlc.table, VLC_BITS, 3);