gallium: implement full reference counting for vertex/fragment programs
authorBrian <brian.paul@tungstengraphics.com>
Wed, 7 May 2008 04:13:06 +0000 (22:13 -0600)
committerBrian <brian.paul@tungstengraphics.com>
Wed, 7 May 2008 04:13:06 +0000 (22:13 -0600)
commit103ae5d16fd9fef566096570f731bb634a8025d4
tree184578514c317c199b6b05bee1f3c57bf3e19877
parent10f6ae0355937615d137c79c060b9e5a923f0d65
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...
src/mesa/main/context.c
src/mesa/main/mtypes.h
src/mesa/main/state.c
src/mesa/shader/prog_cache.c
src/mesa/shader/program.c
src/mesa/shader/program.h
src/mesa/shader/shader_api.c
src/mesa/shader/slang/slang_link.c
src/mesa/state_tracker/st_atom_shader.c
src/mesa/state_tracker/st_context.c
src/mesa/state_tracker/st_program.h