Fix (unreported) potentially giant memory leak in Cloth collision solver.
Not freeing its BVHTree in case there were no collision objects, could quickly lead to hundreds of MB of memleak!
This commit is contained in:
parent
107f1c0a2b
commit
c6bbe6c5aa
|
@ -1357,6 +1357,7 @@ void cloth_find_point_contacts(Object *ob, ClothModifierData *clmd, float step,
|
|||
if (!collobjs) {
|
||||
*r_collider_contacts = NULL;
|
||||
*r_totcolliders = 0;
|
||||
BLI_bvhtree_free(cloth_bvh);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue