in btSimpleBroadphase::destroyProxy(), remove pairs before freeing proxy

This commit is contained in:
Stephen Gold
2019-04-02 21:51:58 -07:00
committed by GitHub
parent 0e23257855
commit 231195843f

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();
}