Guard against negative scale set through LSL functions

This commit is contained in:
Melanie Thielker
2008-10-04 14:23:33 +00:00
parent 5b901c7031
commit 6bf521c7df
2 changed files with 8 additions and 0 deletions

View File

@@ -1115,6 +1115,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
if (part == null || part.ParentGroup == null || part.ParentGroup.RootPart == null)
return;
if (scale.x < 0.01 || scale.y < 0.01 || scale.z < 0.01)
return;
if (part.ParentGroup.RootPart.PhysActor != null && part.ParentGroup.RootPart.PhysActor.IsPhysical)
{
if (scale.x > World.m_maxPhys)