From 6687a7212b995d33a317d2b2463bd2c4d78c6784 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fr=C3=A9d=C3=A9ric=20Dalleau?= Date: Thu, 19 Sep 2013 09:55:00 +0200 Subject: [PATCH] VirtioGL: Fix abort in case of XDestroyImage with NULL pointer. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Frédéric Dalleau Change-Id: Ie011d9c3efbc15c8db4bf53ceb436bc48561d228 --- libGL/client_glx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libGL/client_glx.c b/libGL/client_glx.c index aeda705..77d308b 100755 --- a/libGL/client_glx.c +++ b/libGL/client_glx.c @@ -624,7 +624,8 @@ out_try_non_shm: return rdata; } } - XDestroyImage(rdata->image); + if (rdata->image) + XDestroyImage(rdata->image); if (rdata->gc) XFreeGC(dpy, rdata->gc); free(rdata); -- 2.7.4