aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/state_tracker/st_context.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-08-17 10:54:15 +0200
committermarha <marha@users.sourceforge.net>2012-08-17 10:54:15 +0200
commit5d9b8cf0e4054e774f906cde9dd6b61ceca72d44 (patch)
tree2a15e0622fdb009a0aac84019dce232a245f2e0b /mesalib/src/mesa/state_tracker/st_context.c
parent4aac32998c2b173b84aec0b020aa086fef4b1423 (diff)
downloadvcxsrv-5d9b8cf0e4054e774f906cde9dd6b61ceca72d44.tar.gz
vcxsrv-5d9b8cf0e4054e774f906cde9dd6b61ceca72d44.tar.bz2
vcxsrv-5d9b8cf0e4054e774f906cde9dd6b61ceca72d44.zip
fontconfig mesa git update 17 Aug 2012
Diffstat (limited to 'mesalib/src/mesa/state_tracker/st_context.c')
-rw-r--r--mesalib/src/mesa/state_tracker/st_context.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/mesalib/src/mesa/state_tracker/st_context.c b/mesalib/src/mesa/state_tracker/st_context.c
index 2f9516178..7735eee4f 100644
--- a/mesalib/src/mesa/state_tracker/st_context.c
+++ b/mesalib/src/mesa/state_tracker/st_context.c
@@ -237,7 +237,7 @@ struct st_context *st_create_context(gl_api api, struct pipe_context *pipe,
static void st_destroy_context_priv( struct st_context *st )
{
- uint i;
+ uint shader, i;
st_destroy_atoms( st );
st_destroy_draw( st );
@@ -248,14 +248,11 @@ static void st_destroy_context_priv( struct st_context *st )
st_destroy_drawpix(st);
st_destroy_drawtex(st);
- for (i = 0; i < Elements(st->state.fragment_sampler_views); i++) {
- pipe_sampler_view_release(st->pipe,
- &st->state.fragment_sampler_views[i]);
- }
-
- for (i = 0; i < Elements(st->state.vertex_sampler_views); i++) {
- pipe_sampler_view_release(st->pipe,
- &st->state.vertex_sampler_views[i]);
+ for (shader = 0; shader < Elements(st->state.sampler_views); shader++) {
+ for (i = 0; i < Elements(st->state.sampler_views[0]); i++) {
+ pipe_sampler_view_release(st->pipe,
+ &st->state.sampler_views[shader][i]);
+ }
}
if (st->default_texture) {