From 42f351db0d315873b2b1fe34ada73126da65be3b Mon Sep 17 00:00:00 2001 From: "Wilson E. Alvarez" Date: Tue, 13 Mar 2018 15:24:30 -0400 Subject: [PATCH] Fixed leak in BulletPhysicsServer (cherry picked from commit e5ae9750ed011c545cf2c002159f5095a9592e7c) --- modules/bullet/bullet_physics_server.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/bullet/bullet_physics_server.cpp b/modules/bullet/bullet_physics_server.cpp index c4f9f8800cd..2e6c885b08e 100644 --- a/modules/bullet/bullet_physics_server.cpp +++ b/modules/bullet/bullet_physics_server.cpp @@ -89,7 +89,9 @@ BulletPhysicsServer::BulletPhysicsServer() : active(true), active_spaces_count(0) {} -BulletPhysicsServer::~BulletPhysicsServer() {} +BulletPhysicsServer::~BulletPhysicsServer() { + bulletdelete(emptyShape); +} RID BulletPhysicsServer::shape_create(ShapeType p_shape) { ShapeBullet *shape = NULL;