mesa: Unbind deleted vbo using _mesa_bind_vertex_buffer.
authorMathias Fröhlich <mathias.froehlich@web.de>
Fri, 17 Jun 2016 06:09:04 +0000 (08:09 +0200)
committerMathias Fröhlich <mathias.froehlich@web.de>
Sun, 31 Jul 2016 08:05:45 +0000 (10:05 +0200)
commitf7cb46a9721ace5ec6d1e51cdc4ce70348605701
tree13c01a8136b8f49a7d76faa2b4cb339213c245ef
parentf696b712d7b7c7b701667691bc044b42c1195a69
mesa: Unbind deleted vbo using _mesa_bind_vertex_buffer.

When a vertex buffer object gets deleted, it is unbound
at the VAO. To do this use _mesa_bind_vertex_buffer instead
of plain unreferencing the buffer object. This keeps the VAOs
internal state consistent. In this case it showed up with
gl_vertex_array_object::VertexAttribBufferMask getting out of
sync.

Signed-off-by: Mathias Fröhlich <Mathias.Froehlich@web.de>
Reviewed-by: Eric Anholt <eric@anholt.net>
src/mesa/main/bufferobj.c