summaryrefslogtreecommitdiffstats
path: root/video/vdpau.c
diff options
context:
space:
mode:
Diffstat (limited to 'video/vdpau.c')
-rw-r--r--video/vdpau.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/video/vdpau.c b/video/vdpau.c
index 8d0b524b60..b07926276d 100644
--- a/video/vdpau.c
+++ b/video/vdpau.c
@@ -474,6 +474,9 @@ struct mp_vdpau_ctx *mp_vdpau_create_device_x11(struct mp_log *log, Display *x11
void mp_vdpau_destroy(struct mp_vdpau_ctx *ctx)
{
+ if (!ctx)
+ return;
+
struct vdp_functions *vdp = &ctx->vdp;
VdpStatus vdp_st;