gallium: implement full reference counting for vertex/fragment programs
Use _mesa_reference_vert/fragprog() wherever we assign program pointers. Fixes a memory corruption bug found with glean/api2 test. Another memory bug involving shaders yet to be fixed... Picked from gallium-0.1
This commit is contained in:
@@ -158,6 +158,9 @@ static void st_destroy_context_priv( struct st_context *st )
|
||||
{
|
||||
uint i;
|
||||
|
||||
st_reference_fragprog(st, &st->fp, NULL);
|
||||
st_reference_vertprog(st, &st->vp, NULL);
|
||||
|
||||
draw_destroy(st->draw);
|
||||
st_destroy_atoms( st );
|
||||
st_destroy_draw( st );
|
||||
|
Reference in New Issue
Block a user