summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/draw/draw_pipe_aapoint.c
diff options
context:
space:
mode:
authorKeith Whitwell <keithw@vmware.com>2009-06-01 20:16:20 -0700
committerKeith Whitwell <keithw@vmware.com>2009-06-01 20:35:38 -0700
commit1aef032d438aaa40ec28bf279ad5c089370773f0 (patch)
tree4b81fd950167611e0a8e9ab73c34187cb2860bc6 /src/gallium/auxiliary/draw/draw_pipe_aapoint.c
parent003cfd4dd2491675058c53a8f59553f2443be349 (diff)
gallium/draw: Free specialized versions of driver shaders
The pstipple, aaline and aapoint code would create specialized versions of shaders and upload them to the driver -- but never free them.
Diffstat (limited to 'src/gallium/auxiliary/draw/draw_pipe_aapoint.c')
-rw-r--r--src/gallium/auxiliary/draw/draw_pipe_aapoint.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/draw/draw_pipe_aapoint.c b/src/gallium/auxiliary/draw/draw_pipe_aapoint.c
index 729cf75e65..ae1712fe12 100644
--- a/src/gallium/auxiliary/draw/draw_pipe_aapoint.c
+++ b/src/gallium/auxiliary/draw/draw_pipe_aapoint.c
@@ -829,8 +829,13 @@ aapoint_delete_fs_state(struct pipe_context *pipe, void *fs)
{
struct aapoint_stage *aapoint = aapoint_stage_from_pipe(pipe);
struct aapoint_fragment_shader *aafs = (struct aapoint_fragment_shader *) fs;
+
/* pass-through */
aapoint->driver_delete_fs_state(aapoint->pipe, aafs->driver_fs);
+
+ if (aafs->aapoint_fs)
+ aapoint->driver_delete_fs_state(aapoint->pipe, aafs->aapoint_fs);
+
FREE(aafs);
}