diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c index f784cbff8c..7b4d853b69 100644 --- a/libavfilter/avfilter.c +++ b/libavfilter/avfilter.c @@ -75,8 +75,8 @@ void avfilter_unref_buffer(AVFilterBufferRef *ref) return; if (!(--ref->buf->refcount)) ref->buf->free(ref->buf); - av_free(ref->video); - av_free(ref->audio); + av_freep(&ref->video); + av_freep(&ref->audio); av_free(ref); }