History

avcodec/wavpack: Fix invalid shift

Fixes: runtime error: left shift of 1 by 31 places cannot be represented in type 'int' Fixes: 2377/clusterfuzz-testcase-minimized-6108505935183872

Michael Niedermayer committed 9 years ago

Commit c07af721 parent 7592d971 file · +2 −2Browse files

Unified · Split

libavcodec/wavpack.c+2−2
@@ -846,9 +846,9 @@ static int wavpack_decode_block(AVCodecContext *avctx, int block_no, · 845 unmodified lines
846846 continue;
847847 }
848848 bytestream2_get_buffer(&gb, val, 4);
849− if (val[0] > 31) {
849+ if (val[0] > 30) {
850850 av_log(avctx, AV_LOG_ERROR,
851− "Invalid INT32INFO, extra_bits = %d (> 32)\n", val[0]);
851+ "Invalid INT32INFO, extra_bits = %d (> 30)\n", val[0]);
852852 continue;
853853 } else if (val[0]) {
854854 s->extra_bits = val[0];

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