From 361bccb4ecf90b56da1355e077a5da477aa2f520 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Mon, 16 Jan 2006 16:17:18 +0000 Subject: [PATCH] Free visinfo object (Tilman Sauerbeck) --- progs/xdemos/glxinfo.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/progs/xdemos/glxinfo.c b/progs/xdemos/glxinfo.c index 46311bd645f..957761273c1 100644 --- a/progs/xdemos/glxinfo.c +++ b/progs/xdemos/glxinfo.c @@ -262,6 +262,7 @@ print_screen_info(Display *dpy, int scrnum, Bool allowDirect, GLboolean limits) ctx = glXCreateContext( dpy, visinfo, NULL, allowDirect ); if (!ctx) { fprintf(stderr, "Error: glXCreateContext failed\n"); + XFree(visinfo); XDestroyWindow(dpy, win); return; } @@ -336,6 +337,7 @@ print_screen_info(Display *dpy, int scrnum, Bool allowDirect, GLboolean limits) } glXDestroyContext(dpy, ctx); + XFree(visinfo); XDestroyWindow(dpy, win); } -- 2.30.2