History

avcodec/ffv1dec: Fix off by 1 error with quant tables

Fixes: assertion failure Fixes: 28447/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FFV1_fuzzer-5369575948550144

Michael Niedermayer committed 5 years ago

Commit 5cae71d1 parent c0e660b1 file · +1 −1Browse files

Unified · Split

libavcodec/ffv1dec.c+1−1
@@ -786,7 +786,7 @@ static int read_header(FFV1Context *f) · 785 unmodified lines
786 786
787 if (f->version == 2) {787 if (f->version == 2) {
788 int idx = get_symbol(c, state, 0);788 int idx = get_symbol(c, state, 0);
789 if (idx > (unsigned)f->quant_table_count) {789 if (idx >= (unsigned)f->quant_table_count) {
790 av_log(f->avctx, AV_LOG_ERROR,790 av_log(f->avctx, AV_LOG_ERROR,
791 "quant_table_index out of range\n");791 "quant_table_index out of range\n");
792 return AVERROR_INVALIDDATA;792 return AVERROR_INVALIDDATA;

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