[Mesa-dev] [PATCH] nv50: free interpolation parameters in nv50_program_destroy()

Ilia Mirkin imirkin at alum.mit.edu
Sat Nov 14 14:12:47 PST 2015


Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu>

Thanks! I missed this in all the commotion of trying to get it
actually working :)

On Sat, Nov 14, 2015 at 5:00 PM, Samuel Pitoiset
<samuel.pitoiset at gmail.com> wrote:
> As for nvc0, we need to free memory allocated by interpolation
> parameters. This fixes a memory leak spotted by valgrind.
>
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> ---
>  src/gallium/drivers/nouveau/nv50/nv50_program.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/gallium/drivers/nouveau/nv50/nv50_program.c b/src/gallium/drivers/nouveau/nv50/nv50_program.c
> index 89e7a33..707bf7a 100644
> --- a/src/gallium/drivers/nouveau/nv50/nv50_program.c
> +++ b/src/gallium/drivers/nouveau/nv50/nv50_program.c
> @@ -489,7 +489,7 @@ nv50_program_destroy(struct nv50_context *nv50, struct nv50_program *p)
>     FREE(p->code);
>
>     FREE(p->fixups);
> -
> +   FREE(p->interps);
>     FREE(p->so);
>
>     memset(p, 0, sizeof(*p));
> --
> 2.5.3
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list