Add safety check

This commit is contained in:
Chuyuan Fu 2019-05-16 18:13:29 -07:00
parent 7b06293a97
commit 64ebe27477

View File

@ -80,6 +80,7 @@ static DBVT_INLINE void deletenode(btDbvt* pdbvt,
static void recursedeletenode(btDbvt* pdbvt,
btDbvtNode* node)
{
if (node == 0) return;
if (!node->isleaf())
{
recursedeletenode(pdbvt, node->childs[0]);