[Mesa-dev] [PATCH 6/6] st/mesa: Reset the constant buffers before destroying the pipe context.
Tilman Sauerbeck
tilman at code-monkey.de
Sun Oct 31 09:38:58 PDT 2010
Signed-off-by: Tilman Sauerbeck <tilman at code-monkey.de>
---
src/mesa/state_tracker/st_context.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c
index b5ea6d0..c0bfbea 100644
--- a/src/mesa/state_tracker/st_context.c
+++ b/src/mesa/state_tracker/st_context.c
@@ -238,6 +238,10 @@ void st_destroy_context( struct st_context *st )
pipe->set_index_buffer(pipe, NULL);
+ for (i = 0; i < PIPE_SHADER_TYPES; i++) {
+ pipe_resource_reference(&st->state.constants[PIPE_SHADER_VERTEX], NULL);
+ }
+
_mesa_delete_program_cache(st->ctx, st->pixel_xfer.cache);
_vbo_DestroyContext(st->ctx);
--
1.7.3.1
More information about the mesa-dev
mailing list