History

avcodec/hevc/ps: use unsigned shift

Fixes: left shift of 1 by 31 places cannot be represented in type 'int' Fixes: 70726/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HEVC_fuzzer-6149928703819776

Michael Niedermayer committed 2 years ago

Commit 67947f21 parent 04387591 file · +1 −1Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/hevc/ps.c+1−1
@@ -1101,7 +1101,7 @@ int ff_hevc_parse_sps(HEVCSPS *sps, GetBitContext *gb, unsigned int *sps_id, · 1100 unmodified lines
11011101 sps->used_by_curr_pic_lt = 0;
11021102 for (i = 0; i < sps->num_long_term_ref_pics_sps; i++) {
11031103 sps->lt_ref_pic_poc_lsb_sps[i] = get_bits(gb, sps->log2_max_poc_lsb);
1104− sps->used_by_curr_pic_lt |= get_bits1(gb) * (1 << i);
1104+ sps->used_by_curr_pic_lt |= get_bits1(gb) << i;
11051105 }
11061106 }
11071107

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t