summaryrefslogtreecommitdiff
path: root/src/mesa/main/bufferobj.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/bufferobj.c')
-rw-r--r--src/mesa/main/bufferobj.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c
index 2271550efe..dabb1386ca 100644
--- a/src/mesa/main/bufferobj.c
+++ b/src/mesa/main/bufferobj.c
@@ -556,6 +556,17 @@ _mesa_init_buffer_objects( GLcontext *ctx )
}
+void
+_mesa_free_buffer_objects( GLcontext *ctx )
+{
+ _mesa_reference_buffer_object(ctx, &ctx->Array.ArrayBufferObj, NULL);
+ _mesa_reference_buffer_object(ctx, &ctx->Array.ElementArrayBufferObj, NULL);
+
+ _mesa_reference_buffer_object(ctx, &ctx->CopyReadBuffer, NULL);
+ _mesa_reference_buffer_object(ctx, &ctx->CopyWriteBuffer, NULL);
+}
+
+
/**
* Bind the specified target to buffer for the specified context.
* Called by glBindBuffer() and other functions.