diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2014-11-11 17:40:04 +0100 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2014-11-13 01:41:26 +0100 |
commit | 6abe7edabb7d57e82d7ea6312d30cf05d2192c5b (patch) | |
tree | f3e45d7f6a1c0431a1205b259f528c0aca9a3f2a /libavcodec | |
parent | 5aa710f46119bb9c1c38542f80f5338eb8b5ffb2 (diff) | |
download | ffmpeg-6abe7edabb7d57e82d7ea6312d30cf05d2192c5b.tar.gz |
ffv1: fix out-of-bounds read
CC: libav-stable@libav.org
Bug-Id: CID 1047234
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/ffv1enc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/ffv1enc.c b/libavcodec/ffv1enc.c index 179453db5e..93630b42e8 100644 --- a/libavcodec/ffv1enc.c +++ b/libavcodec/ffv1enc.c @@ -71,7 +71,7 @@ static void find_best_state(uint8_t best_state[256][256], best_len[k] = len; best_state[i][k] = j; } - for (m = 0; m < 256; m++) + for (m = 1; m < 256; m++) if (occ[m]) { newocc[one_state[m]] += occ[m] * p; newocc[256 - one_state[256 - m]] += occ[m] * (1 - p); |