Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikk...@gmail.com> --- src/glx/glxcmds.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/src/glx/glxcmds.c b/src/glx/glxcmds.c index 38a5262..4d8d0c2 100644 --- a/src/glx/glxcmds.c +++ b/src/glx/glxcmds.c @@ -1392,13 +1392,16 @@ void __glXClientInfo(Display * dpy, int opcode) { char *ext_str = __glXGetClientGLExtensionString(); - int size = strlen(ext_str) + 1; - xcb_connection_t *c = XGetXCBConnection(dpy); - xcb_glx_client_info(c, - GLX_MAJOR_VERSION, GLX_MINOR_VERSION, size, ext_str); + if (ext_str) { + int size = strlen(ext_str) + 1; - free(ext_str); + xcb_connection_t *c = XGetXCBConnection(dpy); + xcb_glx_client_info(c, GLX_MAJOR_VERSION, GLX_MINOR_VERSION, size, + ext_str); + + free(ext_str); + } } -- 1.8.1.2 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev