mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-19 05:49:09 +02:00
avcodec/mlpdec: Do not leave a invalid num_primitive_matrices in the context
Fixes: runtime error: index 8 out of bounds for type 'uint8_t [8]' Fixes: 1699/clusterfuzz-testcase-minimized-6327177438035968 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 64ea4d102a070b95832ae4a751688f87da7760a2) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
3ecff1b7e5
commit
4117f19f2f
@ -742,6 +742,7 @@ static int read_matrix_params(MLPDecodeContext *m, unsigned int substr, GetBitCo
|
||||
av_log(m->avctx, AV_LOG_ERROR,
|
||||
"Number of primitive matrices cannot be greater than %d.\n",
|
||||
max_primitive_matrices);
|
||||
s->num_primitive_matrices = 0;
|
||||
return AVERROR_INVALIDDATA;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user