diff --git a/OpenSim/Region/PhysicsModules/ubOde/ODEScene.cs b/OpenSim/Region/PhysicsModules/ubOde/ODEScene.cs index ae84f3d0b8..975bbeca31 100644 --- a/OpenSim/Region/PhysicsModules/ubOde/ODEScene.cs +++ b/OpenSim/Region/PhysicsModules/ubOde/ODEScene.cs @@ -1582,7 +1582,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde //waitForSpaceUnlock(currentspace); SafeNativeMethods.SpaceRemove(currentspace, geom); - if (SafeNativeMethods.SpaceGetSublevel(currentspace) > 2 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0) + if (SafeNativeMethods.SpaceGetSublevel(currentspace) == 0 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0) { SafeNativeMethods.SpaceDestroy(currentspace); } @@ -1603,7 +1603,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde //waitForSpaceUnlock(currentspace); SafeNativeMethods.SpaceRemove(currentspace, geom); - if (SafeNativeMethods.SpaceGetSublevel(currentspace) > 2 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0) + if (SafeNativeMethods.SpaceGetSublevel(currentspace) == 0 && SafeNativeMethods.SpaceGetNumGeoms(currentspace) == 0) { SafeNativeMethods.SpaceDestroy(currentspace); }