History

avcodec/ffv1dec: replace literal 65535 by what it is

should make the code easier to understand

Michael Niedermayer committed 1 year ago

Commit 522fc381 parent 5ca14b21 file · +1 −1Browse files

Unified · Split

libavcodec/ffv1dec.c+1−1
@@ -326,7 +326,7 @@ static int decode_remap(FFV1Context *f, FFV1SliceContext *sc) · 325 unmodified lines
326326 }
327327 if (i == end)
328328 break;
329− if (i - 1 > end || j > 65535)
329+ if (i - 1 > end || j >= FF_ARRAY_ELEMS(sc->fltmap[p]))
330330 return AVERROR_INVALIDDATA;
331331 if (end <= 0xFFFF) {
332332 sc->fltmap [p][j++] = i ^ ((i& 0x8000) ? 0 : flip);

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