mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avcodec/huffyuvdec: Use assert to check for things that can't fail
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
a6d6c8442c
commit
f3c8d0399a
@ -290,13 +290,13 @@ static int read_old_huffman_tables(HYuvDecContext *s)
|
|||||||
|
|
||||||
bytestream2_init(&gb, classic_shift_luma,
|
bytestream2_init(&gb, classic_shift_luma,
|
||||||
sizeof(classic_shift_luma));
|
sizeof(classic_shift_luma));
|
||||||
if ((ret = read_len_table(s->len[0], &gb, 256)) < 0)
|
ret = read_len_table(s->len[0], &gb, 256);
|
||||||
return ret;
|
av_assert1(ret >= 0);
|
||||||
|
|
||||||
bytestream2_init(&gb, classic_shift_chroma,
|
bytestream2_init(&gb, classic_shift_chroma,
|
||||||
sizeof(classic_shift_chroma));
|
sizeof(classic_shift_chroma));
|
||||||
if ((ret = read_len_table(s->len[1], &gb, 256)) < 0)
|
ret = read_len_table(s->len[1], &gb, 256);
|
||||||
return ret;
|
av_assert1(ret >= 0);
|
||||||
|
|
||||||
for (i = 0; i < 256; i++)
|
for (i = 0; i < 256; i++)
|
||||||
s->bits[0][i] = classic_add_luma[i];
|
s->bits[0][i] = classic_add_luma[i];
|
||||||
|
Loading…
Reference in New Issue
Block a user