mesa: Prevent repeated glDeleteProgram() from blowing away our refcounts.
authorEric Anholt <eric@anholt.net>
Tue, 4 Oct 2011 22:36:15 +0000 (15:36 -0700)
committerEric Anholt <eric@anholt.net>
Mon, 10 Oct 2011 18:38:52 +0000 (11:38 -0700)
commitd950a778b7b86526d3968deee232444af64d8cf1
tree19ea125ef7f4657db2d6638eacf8721752c38674
parent7457da5edd4a33c2581f10608ce5bcf0e254c5f9
mesa: Prevent repeated glDeleteProgram() from blowing away our refcounts.

glDeleteProgram should only be able to remove the one refcount for the
user's reference to the program from the hash table (even though that
ref does live on in the hash table until the last other ref is
removed).

Fixes piglit ARB_shader_objects/delete-repeat.

Reviewed-by: Chad Versace <chad@chad-versace.us>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
src/mesa/main/shaderapi.c