diff options
Diffstat (limited to 'progs/xdemos/glxinfo.c')
-rw-r--r-- | progs/xdemos/glxinfo.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/progs/xdemos/glxinfo.c b/progs/xdemos/glxinfo.c index 445d3ea94b6..b182a3091d1 100644 --- a/progs/xdemos/glxinfo.c +++ b/progs/xdemos/glxinfo.c @@ -427,8 +427,6 @@ print_screen_info(Display *dpy, int scrnum, Bool allowDirect, GLboolean limits) int nConfigs; if (!visinfo) - configs = glXChooseFBConfig(dpy, scrnum, fbAttribSingle, &nConfigs); - if (!visinfo) configs = glXChooseFBConfig(dpy, scrnum, fbAttribDouble, &nConfigs); if (configs) { @@ -964,8 +962,10 @@ print_fbconfig_info(Display *dpy, int scrnum, InfoMode mode) /* get list of all fbconfigs on this screen */ fbconfigs = glXGetFBConfigs(dpy, scrnum, &numFBConfigs); - if (numFBConfigs == 0) + if (numFBConfigs == 0) { + XFree(fbconfigs); return; + } printf("%d GLXFBConfigs:\n", numFBConfigs); if (mode == Normal) |