From e9fbf69aeab590d5f292a7ca6bdeb5d2791f9918 Mon Sep 17 00:00:00 2001 From: Brian Date: Wed, 1 Aug 2007 08:40:49 -0600 Subject: [PATCH] fix mem leak (bug 11791) --- src/glut/glx/glut_dstr.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/glut/glx/glut_dstr.c b/src/glut/glx/glut_dstr.c index ec9386f3e50..2513af45394 100644 --- a/src/glut/glx/glut_dstr.c +++ b/src/glut/glx/glut_dstr.c @@ -291,6 +291,7 @@ loadVisuals(int *nitems_return) fbmodes = (FrameBufferMode *) malloc(n * sizeof(FrameBufferMode)); if (fbmodes == NULL) { *nitems_return = -1; + free(vlist); return NULL; } for (i = 0; i < n; i++) { -- 2.30.2