Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-08-11 22:47:31 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2017-08-11 23:02:38 +0300
commit5859b5b4394d3a0d654b6e821c2ba5e1e7842244 (patch)
tree622acf171ee0876a8237a854324b69353e4215c7 /libavcodec/lagarithrac.c
parent0561bd2fc2bff0dbe651d5998e9f129c43d25eb3 (diff)
avcodec/lagarith: Detect end of input in lag_decode_line() loop
Fixes: timeout Fixes: 2933/clusterfuzz-testcase-5124990208835584 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/lagarithrac.c')
-rw-r--r--libavcodec/lagarithrac.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/lagarithrac.c b/libavcodec/lagarithrac.c
index 3d36d1b9e9..cdda67fb81 100644
--- a/libavcodec/lagarithrac.c
+++ b/libavcodec/lagarithrac.c
@@ -46,6 +46,7 @@ void ff_lag_rac_init(lag_rac *l, GetBitContext *gb, int length)
l->range = 0x80;
l->low = *l->bytestream >> 1;
l->hash_shift = FFMAX(l->scale, 10) - 10;
+ l->overread = 0;
for (i = j = 0; i < 1024; i++) {
unsigned r = i << l->hash_shift;