From 2a5a14f3ca516410ba599edc7ae400fb9286b0d2 Mon Sep 17 00:00:00 2001 From: Paul B Mahol Date: Fri, 4 Mar 2022 13:41:24 +0100 Subject: [PATCH] avfilter/avf_aphasemeter: make frame writable before writing to it --- libavfilter/avf_aphasemeter.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavfilter/avf_aphasemeter.c b/libavfilter/avf_aphasemeter.c index d9302cf867..852fcc8ef7 100644 --- a/libavfilter/avf_aphasemeter.c +++ b/libavfilter/avf_aphasemeter.c @@ -266,6 +266,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in) memset(out->data[0] + i * out->linesize[0], 0, outlink->w * 4); } else if (s->do_video) { out = s->out; + av_frame_make_writable(s->out); for (i = outlink->h - 1; i >= 10; i--) memmove(out->data[0] + (i ) * out->linesize[0], out->data[0] + (i-1) * out->linesize[0],