libavfilter/graphparser.c:474: error: Use After Free
  call to `avfilter_free()` eventually accesses memory that was invalidated by call to `free()` on line 474 indirectly during the call to `avfilter_free()`.

libavfilter/graphparser.c:418:1: invalidation part of the trace starts here
416. }
417. 
418. int avfilter_graph_parse2(AVFilterGraph *graph, const char *filters,
     ^
419.                           AVFilterInOut **inputs,
420.                           AVFilterInOut **outputs)

libavfilter/graphparser.c:418:1: parameter `graph` of avfilter_graph_parse2
  416. }
  417. 
  418. int avfilter_graph_parse2(AVFilterGraph *graph, const char *filters,
       ^
  419.                           AVFilterInOut **inputs,
  420.                           AVFilterInOut **outputs)

libavfilter/graphparser.c:474:9: when calling `avfilter_free` here
  472.  fail:
  473.     while (graph->nb_filters)
  474.         avfilter_free(graph->filters[0]);
               ^
  475.     av_freep(&graph->filters);
  476.     avfilter_inout_free(&open_inputs);

libavfilter/avfilter.c:491:1: parameter `filter` of avfilter_free
    489. }
    490. 
    491. void avfilter_free(AVFilterContext *filter)
         ^
    492. {
    493.     int i;

libavfilter/avfilter.c:518:5: when calling `av_free` here
    516.     av_freep(&filter->priv);
    517.     av_freep(&filter->internal);
    518.     av_free(filter);
             ^
    519. }
    520. 

libavutil/mem.c:190:1: parameter `ptr` of av_free
      188. }
      189. 
      190. void av_free(void *ptr)
           ^
      191. {
      192. #if CONFIG_MEMALIGN_HACK

libavutil/mem.c:198:5: was invalidated by call to `free()`
      196.     _aligned_free(ptr);
      197. #else
      198.     free(ptr);
               ^
      199. #endif
      200. }

libavfilter/graphparser.c:418:1: use-after-lifetime part of the trace starts here
416. }
417. 
418. int avfilter_graph_parse2(AVFilterGraph *graph, const char *filters,
     ^
419.                           AVFilterInOut **inputs,
420.                           AVFilterInOut **outputs)

libavfilter/graphparser.c:418:1: parameter `graph` of avfilter_graph_parse2
  416. }
  417. 
  418. int avfilter_graph_parse2(AVFilterGraph *graph, const char *filters,
       ^
  419.                           AVFilterInOut **inputs,
  420.                           AVFilterInOut **outputs)

libavfilter/graphparser.c:474:9: when calling `avfilter_free` here
  472.  fail:
  473.     while (graph->nb_filters)
  474.         avfilter_free(graph->filters[0]);
               ^
  475.     av_freep(&graph->filters);
  476.     avfilter_inout_free(&open_inputs);

libavfilter/avfilter.c:491:1: parameter `filter` of avfilter_free
    489. }
    490. 
    491. void avfilter_free(AVFilterContext *filter)
         ^
    492. {
    493.     int i;

libavfilter/avfilter.c:518:5: when calling `av_free` here
    516.     av_freep(&filter->priv);
    517.     av_freep(&filter->internal);
    518.     av_free(filter);
             ^
    519. }
    520. 

libavutil/mem.c:190:1: parameter `ptr` of av_free
      188. }
      189. 
      190. void av_free(void *ptr)
           ^
      191. {
      192. #if CONFIG_MEMALIGN_HACK

libavutil/mem.c:198:5: invalid access occurs here
      196.     _aligned_free(ptr);
      197. #else
      198.     free(ptr);
               ^
      199. #endif
      200. }
