History

avcodec/ffv1dec: Fix end computation with ec=2

Michael Niedermayer committed 2 years ago

Commit 10e5af11 parent 8e52b151 file · +1 −1Browse files

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

Unified · Split

libavcodec/ffv1dec.c+1−1
@@ -347,7 +347,7 @@ static int decode_slice(AVCodecContext *c, void *arg) · 346 unmodified lines
347 if (f->ac != AC_GOLOMB_RICE && f->version > 2) {347 if (f->ac != AC_GOLOMB_RICE && f->version > 2) {
348 int v;348 int v;
349 get_rac(&sc->c, (uint8_t[]) { 129 });349 get_rac(&sc->c, (uint8_t[]) { 129 });
350 v = sc->c.bytestream_end - sc->c.bytestream - 2 - 5*f->ec;350 v = sc->c.bytestream_end - sc->c.bytestream - 2 - 5*!!f->ec;
351 if (v) {351 if (v) {
352 av_log(f->avctx, AV_LOG_ERROR, "bytestream end mismatching by %d\n", v);352 av_log(f->avctx, AV_LOG_ERROR, "bytestream end mismatching by %d\n", v);
353 slice_set_damaged(f, sc);353 slice_set_damaged(f, sc);

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