mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-13 10:30:05 +01:00
avfilter/vf_avgblur: fix heap-buffer overflow
Fixes #8274
(cherry picked from commit f069a9c2a6)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
committed by
Michael Niedermayer
parent
a9b8eda773
commit
ff93d6f710
@@ -149,7 +149,7 @@ static int filter_vertically_##name(AVFilterContext *ctx, void *arg, int jobnr,
|
|||||||
\
|
\
|
||||||
src = s->buffer + x; \
|
src = s->buffer + x; \
|
||||||
ptr = buffer + x; \
|
ptr = buffer + x; \
|
||||||
for (i = 0; i <= radius; i++) { \
|
for (i = 0; i + radius < height && i <= radius; i++) { \
|
||||||
acc += src[(i + radius) * width]; \
|
acc += src[(i + radius) * width]; \
|
||||||
count++; \
|
count++; \
|
||||||
ptr[i * linesize] = acc / count; \
|
ptr[i * linesize] = acc / count; \
|
||||||
|
|||||||
Reference in New Issue
Block a user