Fixed a memory leak in the broadphase