[FFmpeg-cvslog] avfilter/vf_readeia608: fix check for failed av_calloc

Limin Wang git at videolan.org
Mon Dec 23 11:31:16 EET 2019


ffmpeg | branch: master | Limin Wang <lance.lmwang at gmail.com> | Mon Dec 23 12:55:58 2019 +0800| [03eb96f9b7bfa2d2c1a4c9f30dff9fd364157e2b] | committer: Paul B Mahol

avfilter/vf_readeia608: fix check for failed av_calloc

Signed-off-by: Limin Wang <lance.lmwang at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=03eb96f9b7bfa2d2c1a4c9f30dff9fd364157e2b
---

 libavfilter/vf_readeia608.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/libavfilter/vf_readeia608.c b/libavfilter/vf_readeia608.c
index ff096189a9..43c57268fa 100644
--- a/libavfilter/vf_readeia608.c
+++ b/libavfilter/vf_readeia608.c
@@ -121,7 +121,8 @@ static int config_input(AVFilterLink *inlink)
     s->signal = av_calloc(size, sizeof(*s->signal));
     s->code = av_calloc(size, sizeof(*s->code));
     s->temp = av_calloc(size, sizeof(*s->temp));
-    if (!s->temp)
+    if (!s->unfiltered || !s->filtered || !s->avg_filter ||
+        !s->std_filter || !s->signal || !s->code || !s->temp)
         return AVERROR(ENOMEM);
 
     return 0;



More information about the ffmpeg-cvslog mailing list