diff options
author | Ilia Mirkin <[email protected]> | 2015-05-24 02:23:16 -0400 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2015-05-24 02:26:29 -0400 |
commit | 9870ed05dd333a20662479b9b1e3a8db542924c4 (patch) | |
tree | 23f657e6646541099dd6343efaa47ff274ff0279 /src/gallium/drivers/nouveau/nv30/nv30_vertprog.c | |
parent | 605ce36d7f4a90c4062d6940bea82ab483bbe3b2 (diff) |
nv30: avoid leaking render state and draw shaders
Signed-off-by: Ilia Mirkin <[email protected]>
Cc: "10.5 10.6" <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau/nv30/nv30_vertprog.c')
-rw-r--r-- | src/gallium/drivers/nouveau/nv30/nv30_vertprog.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/drivers/nouveau/nv30/nv30_vertprog.c b/src/gallium/drivers/nouveau/nv30/nv30_vertprog.c index 3c1b7e714ea..4d4145d10b5 100644 --- a/src/gallium/drivers/nouveau/nv30/nv30_vertprog.c +++ b/src/gallium/drivers/nouveau/nv30/nv30_vertprog.c @@ -23,6 +23,7 @@ * */ +#include "draw/draw_context.h" #include "util/u_dynarray.h" #include "tgsi/tgsi_parse.h" @@ -237,6 +238,10 @@ nv30_vp_state_delete(struct pipe_context *pipe, void *hwcso) if (vp->translated) nv30_vertprog_destroy(vp); + + if (vp->draw) + draw_delete_vertex_shader(nv30_context(pipe)->draw, vp->draw); + FREE((void *)vp->pipe.tokens); FREE(vp); } |