Merge pull request #2180 from stephengold/master

in btSimpleBroadphase::destroyProxy(), remove pairs before freeing proxy
This commit is contained in:
erwincoumans
2019-04-03 07:32:06 -07:00
committed by GitHub

View File

@@ -123,11 +123,11 @@ protected:
void btSimpleBroadphase::destroyProxy(btBroadphaseProxy* proxyOrg, btDispatcher* dispatcher)
{
m_pairCache->removeOverlappingPairsContainingProxy(proxyOrg, dispatcher);
btSimpleBroadphaseProxy* proxy0 = static_cast<btSimpleBroadphaseProxy*>(proxyOrg);
freeHandle(proxy0);
m_pairCache->removeOverlappingPairsContainingProxy(proxyOrg, dispatcher);
//validate();
}