diff options
author | Paul B Mahol <onemda@gmail.com> | 2020-08-09 11:54:52 +0200 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2020-08-09 18:47:29 +0200 |
commit | 3ff7171a8524cf1e49bbfc6528c02a205b0f4fac (patch) | |
tree | f50cb01473cb29b6ab0bb5eb5b022e23226e7660 /libavcodec | |
parent | 25d07e139412eb4ee7c27a1984e429c716559a95 (diff) | |
download | ffmpeg-3ff7171a8524cf1e49bbfc6528c02a205b0f4fac.tar.gz |
avcodec/cfhd: use init_get_bits8()
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/cfhd.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/cfhd.c b/libavcodec/cfhd.c index 41b6f4f5ee..2d3c402e39 100644 --- a/libavcodec/cfhd.c +++ b/libavcodec/cfhd.c @@ -815,7 +815,9 @@ static int cfhd_decode(AVCodecContext *avctx, void *data, int *got_frame, av_log(avctx, AV_LOG_DEBUG, "Start subband coeffs plane %i level %i codebook %i expected %i\n", s->channel_num, s->level, s->codebook, expected); - init_get_bits(&s->gb, gb.buffer, bytestream2_get_bytes_left(&gb) * 8); + ret = init_get_bits8(&s->gb, gb.buffer, bytestream2_get_bytes_left(&gb)); + if (ret < 0) + goto end; { OPEN_READER(re, &s->gb); |