From: Tapani Pälli Date: Wed, 20 Sep 2017 06:29:16 +0000 (+0300) Subject: mesa: free current ComputeProgram state in _mesa_free_context_data X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=589457d97fa8e95f227e7179e9c89a01dff495a0;p=mesa.git mesa: free current ComputeProgram state in _mesa_free_context_data This is already done for other programs stages, fixes a leak when using compute programs. Signed-off-by: Tapani Pälli Cc: mesa-stable@lists.freedesktop.org Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102844 Reviewed-by: Timothy Arceri Reviewed-by: Samuel Pitoiset --- diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index dad3ab39f84..55a65ac2abe 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c @@ -1329,6 +1329,8 @@ _mesa_free_context_data( struct gl_context *ctx ) _mesa_reference_program(ctx, &ctx->FragmentProgram._Current, NULL); _mesa_reference_program(ctx, &ctx->FragmentProgram._TexEnvProgram, NULL); + _mesa_reference_program(ctx, &ctx->ComputeProgram._Current, NULL); + _mesa_reference_vao(ctx, &ctx->Array.VAO, NULL); _mesa_reference_vao(ctx, &ctx->Array.DefaultVAO, NULL);