diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c index 484eda1c7f..211344c449 100644 --- a/libavfilter/avfilter.c +++ b/libavfilter/avfilter.c @@ -392,6 +392,9 @@ AVFilter *avfilter_get_by_name(const char *name) { AVFilter *f = NULL; + if (!name) + return NULL; + while ((f = avfilter_next(f))) if (!strcmp(f->name, name)) return f;