From: Eric Anholt Date: Tue, 6 Oct 2015 23:32:03 +0000 (-0700) Subject: vc4: Fix a leak of the last color read/write surface on context destroy. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b6cd39fc4761a3a6276a373e68510fb7fb735a77;p=mesa.git vc4: Fix a leak of the last color read/write surface on context destroy. --- diff --git a/src/gallium/drivers/vc4/vc4_context.c b/src/gallium/drivers/vc4/vc4_context.c index 87d781d088d..d490fad5167 100644 --- a/src/gallium/drivers/vc4/vc4_context.c +++ b/src/gallium/drivers/vc4/vc4_context.c @@ -188,6 +188,9 @@ vc4_context_destroy(struct pipe_context *pctx) pipe_surface_reference(&vc4->framebuffer.cbufs[0], NULL); pipe_surface_reference(&vc4->framebuffer.zsbuf, NULL); + pipe_surface_reference(&vc4->color_write, NULL); + pipe_surface_reference(&vc4->color_read, NULL); + vc4_program_fini(pctx); ralloc_free(vc4);