From 7fbb1e8a56ed60cb0ec4455e52469fee6c6fb1d5 Mon Sep 17 00:00:00 2001 From: Waldo Bastian Date: Sat, 10 Nov 2007 17:52:43 -0800 Subject: [PATCH] Generate proper error for NULL display. --- src/va.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/va.c b/src/va.c index 8b9b73b..9ff365a 100644 --- a/src/va.c +++ b/src/va.c @@ -72,6 +72,11 @@ VADisplay vaGetDisplay ( VADisplay dpy = NULL; VADriverContextP ctx = pDriverContexts; + if (!native_dpy) + { + return NULL; + } + while (ctx) { if (ctx->x11_dpy == (Display *)native_dpy) -- 2.7.4