[FFmpeg-cvslog] avfilter/vf_datascope: fix heap buffer overflow
Paul B Mahol
git at videolan.org
Tue Sep 14 00:16:44 EEST 2021
ffmpeg | branch: release/4.1 | Paul B Mahol <onemda at gmail.com> | Sat Oct 19 09:50:53 2019 +0200| [aef4cbec696ae4e349a72521fba1180b96a97fab] | committer: James Almer
avfilter/vf_datascope: fix heap buffer overflow
Fixes #8309
(cherry picked from commit d4d6b7b0355f3597cad3b8d12911790c73b5f96d)
Signed-off-by: James Almer <jamrial at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=aef4cbec696ae4e349a72521fba1180b96a97fab
---
libavfilter/vf_datascope.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavfilter/vf_datascope.c b/libavfilter/vf_datascope.c
index c9039a60f6..83f90f07ba 100644
--- a/libavfilter/vf_datascope.c
+++ b/libavfilter/vf_datascope.c
@@ -973,7 +973,7 @@ static int oscilloscope_filter_frame(AVFilterLink *inlink, AVFrame *frame)
frame->width, frame->height,
s->ox, s->oy, s->width, s->height + 20 * s->statistics);
- if (s->grid) {
+ if (s->grid && outlink->h >= 10) {
ff_fill_rectangle(&s->draw, &s->gray, frame->data, frame->linesize,
s->ox, s->oy, s->width - 1, 1);
More information about the ffmpeg-cvslog
mailing list