diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2014-11-12 19:10:45 +0100 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2014-11-14 20:25:21 +0100 |
commit | 3a6ddfb8745e4b306a5637927fb057f630345e2f (patch) | |
tree | 83067529dac8c3287efa94ef25ae6914a15156ac /libavcodec/exr.c | |
parent | e4cb6abb2f46910c72178e2f987a0198f0fd10b1 (diff) | |
download | ffmpeg-3a6ddfb8745e4b306a5637927fb057f630345e2f.tar.gz |
exr: check return value
CC: libav-stable@libav.org
Bug-Id: CID 1198259
Diffstat (limited to 'libavcodec/exr.c')
-rw-r--r-- | libavcodec/exr.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libavcodec/exr.c b/libavcodec/exr.c index 37a31cebd8..4aa6eaf914 100644 --- a/libavcodec/exr.c +++ b/libavcodec/exr.c @@ -311,8 +311,9 @@ static int huf_unpack_enc_table(GetByteContext *gb, int32_t im, int32_t iM, uint64_t *hcode) { GetBitContext gbit; - - init_get_bits8(&gbit, gb->buffer, bytestream2_get_bytes_left(gb)); + int ret = init_get_bits8(&gbit, gb->buffer, bytestream2_get_bytes_left(gb)); + if (ret < 0) + return ret; for (; im <= iM; im++) { uint64_t l = hcode[im] = get_bits(&gbit, 6); |