unref buffer after drawing, fixes rastpos mem leak
authorBrian <brian.paul@tungstengraphics.com>
Fri, 28 Dec 2007 21:25:09 +0000 (14:25 -0700)
committerBrian <brian.paul@tungstengraphics.com>
Tue, 1 Jan 2008 17:21:21 +0000 (10:21 -0700)
src/mesa/state_tracker/st_draw.c

index b3d463043d41cffd3d1b7dbb37c80a128c7d5d88..96db9e3c03ba38f7e331f7d7a3a448e5b5fd4ae7 100644 (file)
@@ -616,6 +616,7 @@ st_feedback_draw_vbo(GLcontext *ctx,
       if (draw->vertex_buffer[i].buffer) {
          pipe->winsys->buffer_unmap(pipe->winsys,
                                     draw->vertex_buffer[i].buffer);
+         winsys->buffer_reference(winsys, &draw->vertex_buffer[i].buffer, NULL);
          draw_set_mapped_vertex_buffer(draw, i, NULL);
       }
    }