aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorMelanie Thielker2010-08-18 20:17:20 +0200
committerMelanie2010-08-18 20:00:19 +0100
commit6ddf124c8af73d52132c3cc1047d01ac4cbcbadf (patch)
tree058509c4cf12ec08d46cee16be323c3c03ff63fa /OpenSim/Region
parent* Changed a few OSD.FromBinary() calls to the more accurate OSD.FromULong() t... (diff)
downloadopensim-SC_OLD-6ddf124c8af73d52132c3cc1047d01ac4cbcbadf.zip
opensim-SC_OLD-6ddf124c8af73d52132c3cc1047d01ac4cbcbadf.tar.gz
opensim-SC_OLD-6ddf124c8af73d52132c3cc1047d01ac4cbcbadf.tar.bz2
opensim-SC_OLD-6ddf124c8af73d52132c3cc1047d01ac4cbcbadf.tar.xz
Prevent a bad cast in llCreateLink().
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs6
1 files changed, 5 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index b21e532..d38fe9f 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -3505,6 +3505,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
3505 { 3505 {
3506 m_host.AddScriptLPS(1); 3506 m_host.AddScriptLPS(1);
3507 UUID invItemID = InventorySelf(); 3507 UUID invItemID = InventorySelf();
3508 UUID targetID;
3509
3510 if (!UUID.TryParse(target, out targetID))
3511 return;
3508 3512
3509 TaskInventoryItem item; 3513 TaskInventoryItem item;
3510 lock (m_host.TaskInventory) 3514 lock (m_host.TaskInventory)
@@ -3524,7 +3528,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
3524 if (sp != null) 3528 if (sp != null)
3525 client = sp.ControllingClient; 3529 client = sp.ControllingClient;
3526 3530
3527 SceneObjectPart targetPart = World.GetSceneObjectPart((UUID)target); 3531 SceneObjectPart targetPart = World.GetSceneObjectPart((UUID)targetID);
3528 3532
3529 if (targetPart.ParentGroup.RootPart.AttachmentPoint != 0) 3533 if (targetPart.ParentGroup.RootPart.AttachmentPoint != 0)
3530 return; // Fail silently if attached 3534 return; // Fail silently if attached