]> git.sesse.net Git - ffmpeg/commitdiff
avfilter/af_afftfilt: fix possible invalid memory access
authorPaul B Mahol <onemda@gmail.com>
Mon, 7 Oct 2019 09:37:05 +0000 (11:37 +0200)
committerPaul B Mahol <onemda@gmail.com>
Mon, 7 Oct 2019 09:37:05 +0000 (11:37 +0200)
libavfilter/af_afftfilt.c

index 86278ef35b929df656f4ed07dc850deee988f237..28b4bda8da0f8253215d60977ae17eb08e0a2841 100644 (file)
@@ -188,6 +188,8 @@ static int config_input(AVFilterLink *inlink)
     if (!args)
         return AVERROR(ENOMEM);
 
+    saveptr = NULL;
+    last_expr = "1";
     for (ch = 0; ch < inlink->channels; ch++) {
         char *arg = av_strtok(ch == 0 ? args : NULL, "|", &saveptr);