summaryrefslogtreecommitdiff
path: root/libavfilter/vf_datascope.c
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2019-10-19 09:50:53 +0200
committerPaul B Mahol <onemda@gmail.com>2019-10-19 09:50:53 +0200
commitd4d6b7b0355f3597cad3b8d12911790c73b5f96d (patch)
tree9c675bb849a0d8a40bb8e50798b3e2c9e7950f52 /libavfilter/vf_datascope.c
parented78ca41232eb6c041d08972f03c1b453269e81e (diff)
downloadffmpeg-d4d6b7b0355f3597cad3b8d12911790c73b5f96d.tar.gz
avfilter/vf_datascope: fix heap buffer overflow
Fixes #8309
Diffstat (limited to 'libavfilter/vf_datascope.c')
-rw-r--r--libavfilter/vf_datascope.c2
1 files changed, 1 insertions, 1 deletions
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);