Explorar o código

Merge pull request #17493 from Rubonnek/bullet-physics-server-leak

Fixed leak in BulletPhysicsServer
Rémi Verschelde %!s(int64=7) %!d(string=hai) anos
pai
achega
ea204628ad
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      modules/bullet/bullet_physics_server.cpp

+ 3 - 1
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;