aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/svga/svga_context.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/svga/svga_context.c')
-rw-r--r--src/gallium/drivers/svga/svga_context.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/svga/svga_context.c b/src/gallium/drivers/svga/svga_context.c
index 4ef99efe989..d80336cf785 100644
--- a/src/gallium/drivers/svga/svga_context.c
+++ b/src/gallium/drivers/svga/svga_context.c
@@ -75,7 +75,9 @@ svga_destroy(struct pipe_context *pipe)
/* free HW constant buffers */
for (shader = 0; shader < ARRAY_SIZE(svga->state.hw_draw.constbuf); shader++) {
- pipe_resource_reference(&svga->state.hw_draw.constbuf[shader], NULL);
+ for (i = 0; i < ARRAY_SIZE(svga->state.hw_draw.constbuf[0]); i++) {
+ pipe_resource_reference(&svga->state.hw_draw.constbuf[shader][i], NULL);
+ }
}
pipe->delete_blend_state(pipe, svga->noop_blend);