radeon: use _mesa_delete_buffer_object
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Wed, 6 Jan 2016 02:49:37 +0000 (21:49 -0500)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Thu, 7 Jan 2016 22:07:03 +0000 (17:07 -0500)
This is more future-proof, plugs the memory leak of Label and properly
destroys the buffer mutex.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Cc: "11.0 11.1" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
src/mesa/drivers/dri/radeon/radeon_buffer_objects.c

index d9d4f5ffc5e1c11173fadffde9dc3228e57e175e..2b76305dd45c59d65a7f37b4150c03d8bae0b4a0 100644 (file)
@@ -71,7 +71,7 @@ radeonDeleteBufferObject(struct gl_context * ctx,
         radeon_bo_unref(radeon_obj->bo);
     }
 
-    free(radeon_obj);
+    _mesa_delete_buffer_object(ctx, obj);
 }