diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2024-05-17 23:53:28 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2024-05-28 03:48:07 +0200 |
commit | 8814cedb079d5827e07a92e9424c2314bd0a6047 (patch) | |
tree | ea7816350a53c4f6abb2f3caf45854739c6e3ad9 /libavcodec | |
parent | 6df8bd64ffa5ea3864a433c5e78b8d8f642c1305 (diff) | |
download | ffmpeg-8814cedb079d5827e07a92e9424c2314bd0a6047.tar.gz |
avcodec/tiff: Assert init_get_bits8() success in horizontal_fill()
Helps: CID1441167 Unchecked return value
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/tiff.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/tiff.c b/libavcodec/tiff.c index 05ab0e70b0..80f3757f1e 100644 --- a/libavcodec/tiff.c +++ b/libavcodec/tiff.c @@ -422,7 +422,8 @@ static void av_always_inline horizontal_fill(TiffContext *s, uint8_t shift = is_dng ? 0 : 16 - bpp; GetBitContext gb; - init_get_bits8(&gb, src, width); + int ret = init_get_bits8(&gb, src, width); + av_assert1(ret >= 0); for (int i = 0; i < s->width; i++) { dst16[i] = get_bits(&gb, bpp) << shift; } |