mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-24 12:09:55 +00:00
svq1dec: check return value of get_bits1() in more common way
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
e2bf1082cc
commit
8f4020d8a4
@ -100,7 +100,7 @@ static const uint8_t string_table[256] = {
|
||||
break; \
|
||||
} \
|
||||
/* divide block if next bit set */ \
|
||||
if (get_bits1(bitbuf) == 0) \
|
||||
if (!get_bits1(bitbuf)) \
|
||||
break; \
|
||||
/* add child nodes */ \
|
||||
list[n++] = list[i]; \
|
||||
@ -564,7 +564,7 @@ static int svq1_decode_frame_header(GetBitContext *bitbuf, MpegEncContext *s)
|
||||
}
|
||||
|
||||
/* unknown fields */
|
||||
if (get_bits1(bitbuf) == 1) {
|
||||
if (get_bits1(bitbuf)) {
|
||||
skip_bits1(bitbuf); /* use packet checksum if (1) */
|
||||
skip_bits1(bitbuf); /* component checksums after image data if (1) */
|
||||
|
||||
@ -572,13 +572,13 @@ static int svq1_decode_frame_header(GetBitContext *bitbuf, MpegEncContext *s)
|
||||
return AVERROR_INVALIDDATA;
|
||||
}
|
||||
|
||||
if (get_bits1(bitbuf) == 1) {
|
||||
if (get_bits1(bitbuf)) {
|
||||
skip_bits1(bitbuf);
|
||||
skip_bits(bitbuf, 4);
|
||||
skip_bits1(bitbuf);
|
||||
skip_bits(bitbuf, 2);
|
||||
|
||||
while (get_bits1(bitbuf) == 1)
|
||||
while (get_bits1(bitbuf))
|
||||
skip_bits(bitbuf, 8);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user