diff options
Diffstat (limited to 'video')
-rw-r--r-- | video/filter/vf_lavfi.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/video/filter/vf_lavfi.c b/video/filter/vf_lavfi.c index f2de4fe9a4..2002c97d16 100644 --- a/video/filter/vf_lavfi.c +++ b/video/filter/vf_lavfi.c @@ -334,10 +334,13 @@ static int control(vf_instance_t *vf, int request, void *data) case VFCTRL_SEEK_RESET: reset(vf); return CONTROL_OK; - case VFCTRL_GET_METADATA:{ - *(struct mp_tags*) data = *vf->priv->metadata; - return CONTROL_OK; - } + case VFCTRL_GET_METADATA: + if (vf->priv && vf->priv->metadata) { + *(struct mp_tags*) data = *vf->priv->metadata; + return CONTROL_OK; + } else { + return CONTROL_NA; + } } return CONTROL_UNKNOWN; } |