[FFmpeg-cvslog] avfilter/vf_edgedetect: fix coverity issue
Paul B Mahol
git at videolan.org
Mon Oct 14 11:54:06 EEST 2019
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Mon Oct 14 10:52:27 2019 +0200| [996ff3fe86b0a7a0d2b8bc5a2570cb1271eb9474] | committer: Paul B Mahol
avfilter/vf_edgedetect: fix coverity issue
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=996ff3fe86b0a7a0d2b8bc5a2570cb1271eb9474
---
libavfilter/vf_edgedetect.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/libavfilter/vf_edgedetect.c b/libavfilter/vf_edgedetect.c
index 11a31fa4ff..ea0efe0de3 100644
--- a/libavfilter/vf_edgedetect.c
+++ b/libavfilter/vf_edgedetect.c
@@ -150,8 +150,9 @@ static void gaussian_blur(AVFilterContext *ctx, int w, int h,
int i, j;
memcpy(dst, src, w); dst += dst_linesize; src += src_linesize;
- if (h > 1)
+ if (h > 1) {
memcpy(dst, src, w); dst += dst_linesize; src += src_linesize;
+ }
for (j = 2; j < h - 2; j++) {
dst[0] = src[0];
dst[1] = src[1];
@@ -181,8 +182,9 @@ static void gaussian_blur(AVFilterContext *ctx, int w, int h,
dst += dst_linesize;
src += src_linesize;
}
- if (h > 2)
+ if (h > 2) {
memcpy(dst, src, w); dst += dst_linesize; src += src_linesize;
+ }
if (h > 3)
memcpy(dst, src, w);
}
More information about the ffmpeg-cvslog
mailing list