You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-11-23 21:54:53 +02:00
avcodec/utvideodec: Set B for the width= 1 case in restore_median_planar_il()
Fixes: use of uninitialized memory Fixes: 439878388/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_UTVIDEO_DEC_fuzzer-5635866203848704 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
committed by
michaelni
parent
08816b9376
commit
59db32b433
@@ -457,7 +457,7 @@ static void restore_median_planar_il(UtvideoContext *c, uint8_t *src, ptrdiff_t
|
|||||||
// second line - first element has top prediction, the rest uses median
|
// second line - first element has top prediction, the rest uses median
|
||||||
C = bsrc[-stride2];
|
C = bsrc[-stride2];
|
||||||
bsrc[0] += C;
|
bsrc[0] += C;
|
||||||
A = bsrc[0];
|
A = B = bsrc[0];
|
||||||
for (i = 1; i < FFMIN(width, 16); i++) { /* scalar loop (DSP need align 16) */
|
for (i = 1; i < FFMIN(width, 16); i++) { /* scalar loop (DSP need align 16) */
|
||||||
B = bsrc[i - stride2];
|
B = bsrc[i - stride2];
|
||||||
bsrc[i] += mid_pred(A, B, (uint8_t)(A + B - C));
|
bsrc[i] += mid_pred(A, B, (uint8_t)(A + B - C));
|
||||||
|
|||||||
Reference in New Issue
Block a user