diff options
author | Paulo Zanoni <paulo.r.zanoni@intel.com> | 2011-10-25 14:56:35 -0200 |
---|---|---|
committer | Paulo Zanoni <paulo.r.zanoni@intel.com> | 2011-11-24 17:40:01 -0200 |
commit | d26fae246d7c451b4d5ffe24fdb959d4bd00b107 (patch) | |
tree | e0d1b44167342348b58cc6bc987095688f03a7d9 /glx | |
parent | 305a8bcb2fc6f87f8d891fcb774198b6fd118ee1 (diff) |
glx: don't leak fbconfigs
29,952 (208 direct, 29,744 indirect) bytes in 1 blocks are definitely lost in loss record 573 of 573
at 0x4C2779D: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
by 0x4829BC: createModeFromConfig (glxdricommon.c:131)
by 0x482C09: glxConvertConfigs (glxdricommon.c:185)
by 0x482788: __glXDRIscreenProbe (glxdriswrast.c:468)
by 0x4812FA: GlxExtensionInit (glxext.c:327)
by 0x41FB14: InitExtensions (miinitext.c:471)
by 0x568636: main (main.c:208)
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Diffstat (limited to 'glx')
-rw-r--r-- | glx/glxscreens.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/glx/glxscreens.c b/glx/glxscreens.c index ebb9747b4..928cf0c92 100644 --- a/glx/glxscreens.c +++ b/glx/glxscreens.c @@ -419,6 +419,15 @@ void __glXScreenInit(__GLXscreen *pGlxScreen, ScreenPtr pScreen) void __glXScreenDestroy(__GLXscreen *screen) { + __GLXconfig *head, *next; + + head = screen->fbconfigs; + while (head) { + next = head->next; + free(head); + head = next; + } + free(screen->GLXvendor); free(screen->GLXextensions); free(screen->GLextensions); |