summaryrefslogtreecommitdiffstats
path: root/video/filter
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-12-30 13:21:36 +0100
committerwm4 <wm4@nowhere>2014-12-30 13:21:41 +0100
commita5832ba0194d278cb0813daf8b4af564e6848a61 (patch)
treeb142af4a152b34b1b6ad8967db73af454d0e594e /video/filter
parent0fa9986a9803801fdf5e5f2286311542fd72edcf (diff)
downloadmpv-a5832ba0194d278cb0813daf8b4af564e6848a61.tar.bz2
mpv-a5832ba0194d278cb0813daf8b4af564e6848a61.tar.xz
vf: fix crash if filter doesn't provide control entrypoint
This input command crashed: vf add @mf:format=yuv420p ; show_text "${vf-metadata/mf}" Fixes #1408.
Diffstat (limited to 'video/filter')
-rw-r--r--video/filter/vf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/video/filter/vf.c b/video/filter/vf.c
index d3441febf1..a424cc5856 100644
--- a/video/filter/vf.c
+++ b/video/filter/vf.c
@@ -170,7 +170,7 @@ int vf_control_by_label(struct vf_chain *c,int cmd, void *arg, bstr label)
char *label_str = bstrdup0(NULL, label);
struct vf_instance *cur = vf_find_by_label(c, label_str);
talloc_free(label_str);
- if (cur)
+ if (cur && cur->control)
return cur->control(cur, cmd, arg);
else
return CONTROL_UNKNOWN;