diff options
author | Nicolas Bruguier <nicolas.bruguier@supersonicimagine.fr> | 2008-11-29 14:02:54 +0100 |
---|---|---|
committer | Nicolas Bruguier <nicolas.bruguier@supersonicimagine.fr> | 2008-11-29 14:02:54 +0100 |
commit | affc8a9688e3f6c8d2063a7a5201ae6342d24acf (patch) | |
tree | 6d565922eab3806df59b002569a53004d199c23a /src | |
parent | dbaf49d107df1e95eaf13f4c24d79acc2223bf4a (diff) |
[glx] Avoid memleak in glitz_glx_find_drawable_format_for_visual
Free properly XVisual when glitz leave find drawable format for visual
to avoid any memleak.
Diffstat (limited to 'src')
-rw-r--r-- | src/glx/glitz_glx_format.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/glx/glitz_glx_format.c b/src/glx/glitz_glx_format.c index 8f24437..c9e83ca 100644 --- a/src/glx/glitz_glx_format.c +++ b/src/glx/glitz_glx_format.c @@ -425,8 +425,14 @@ glitz_glx_find_drawable_format_for_visual (Display *display, } if (format) + { + if (visinfo) + XFree(visinfo); break; + } } + if (visinfo) + XFree(visinfo); } if (fbconfigs) |