aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2012-01-26 01:16:03 +0000
committerJustin Clark-Casey (justincc)2012-01-26 01:16:03 +0000
commit093469c33c2e2ac10d41cf4daadac3c7fd7ff40c (patch)
treecf0814506e55c57f730d8e8bd8bdec692889bafb /OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
parentRe-enable error logging associated with assembly and script loading failure i... (diff)
downloadopensim-SC-093469c33c2e2ac10d41cf4daadac3c7fd7ff40c.zip
opensim-SC-093469c33c2e2ac10d41cf4daadac3c7fd7ff40c.tar.gz
opensim-SC-093469c33c2e2ac10d41cf4daadac3c7fd7ff40c.tar.bz2
opensim-SC-093469c33c2e2ac10d41cf4daadac3c7fd7ff40c.tar.xz
Add basic TestAddScript() regression test
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Scene.Inventory.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Inventory.cs11
1 files changed, 11 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
index 9293aeb..f344dcc 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
@@ -1646,10 +1646,21 @@ namespace OpenSim.Region.Framework.Scenes
1646 // The part ID is the folder ID! 1646 // The part ID is the folder ID!
1647 SceneObjectPart part = GetSceneObjectPart(itemBase.Folder); 1647 SceneObjectPart part = GetSceneObjectPart(itemBase.Folder);
1648 if (part == null) 1648 if (part == null)
1649 {
1650// m_log.DebugFormat(
1651// "[SCENE INVENTORY]: Could not find part with id {0} for {1} to rez new script",
1652// itemBase.Folder, agentID);
1653
1649 return null; 1654 return null;
1655 }
1650 1656
1651 if (!Permissions.CanCreateObjectInventory(itemBase.InvType, part.UUID, agentID)) 1657 if (!Permissions.CanCreateObjectInventory(itemBase.InvType, part.UUID, agentID))
1658 {
1659// m_log.DebugFormat(
1660// "[SCENE INVENTORY]: No permission to create new script in {0} for {1}", part.Name, agentID);
1661
1652 return null; 1662 return null;
1663 }
1653 1664
1654 AssetBase asset = CreateAsset(itemBase.Name, itemBase.Description, (sbyte)itemBase.AssetType, 1665 AssetBase asset = CreateAsset(itemBase.Name, itemBase.Description, (sbyte)itemBase.AssetType,
1655 Encoding.ASCII.GetBytes("default\n{\n state_entry()\n {\n llSay(0, \"Script running\");\n }\n}"), 1666 Encoding.ASCII.GetBytes("default\n{\n state_entry()\n {\n llSay(0, \"Script running\");\n }\n}"),