[PATCH 1/3] glx: fix memory leak when destroying screen

Jeremy Huddleston jeremyhu at apple.com
Thu Nov 10 23:23:48 PST 2011


For all 3:

Reviewed-by: Jeremy Huddleston <jeremyhu at apple.com>

On Oct 29, 2011, at 2:08 PM, przanoni at gmail.com wrote:

> From: Paulo Zanoni <paulo.r.zanoni at intel.com>
> 
> 1,152 bytes in 1 blocks are definitely lost in loss record 536 of 575
>   at 0x4C25E84: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
>   by 0x483820: __glXScreenInit (glxscreens.c:357)
>   by 0x48271C: __glXDRIscreenProbe (glxdriswrast.c:469)
>   by 0x4812BE: GlxExtensionInit (glxext.c:327)
>   by 0x41FB14: InitExtensions (miinitext.c:471)
>   by 0x5685AE: main (main.c:208)
> 
> Signed-off-by: Paulo Zanoni <paulo.r.zanoni at intel.com>
> ---
> glx/glxscreens.c |    1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/glx/glxscreens.c b/glx/glxscreens.c
> index c4ad426..ebb9747 100644
> --- a/glx/glxscreens.c
> +++ b/glx/glxscreens.c
> @@ -422,4 +422,5 @@ void __glXScreenDestroy(__GLXscreen *screen)
>     free(screen->GLXvendor);
>     free(screen->GLXextensions);
>     free(screen->GLextensions);
> +    free(screen->visuals);
> }
> -- 
> 1.7.7
> 
> _______________________________________________
> xorg-devel at lists.x.org: X.Org development
> Archives: http://lists.x.org/archives/xorg-devel
> Info: http://lists.x.org/mailman/listinfo/xorg-devel
> 



More information about the xorg-devel mailing list