diff options
author | Dr Scofield | 2008-11-14 13:03:18 +0000 |
---|---|---|
committer | Dr Scofield | 2008-11-14 13:03:18 +0000 |
commit | 5c21ec6d108313080ccf8bdf2212ce52ad80bbb5 (patch) | |
tree | 8d039bfe8603ce2c049a8f26f44fa121ab372afe /OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |
parent | From: Christopher Yeoh <cyeoh@au1.ibm.com> (diff) | |
download | opensim-SC-5c21ec6d108313080ccf8bdf2212ce52ad80bbb5.zip opensim-SC-5c21ec6d108313080ccf8bdf2212ce52ad80bbb5.tar.gz opensim-SC-5c21ec6d108313080ccf8bdf2212ce52ad80bbb5.tar.bz2 opensim-SC-5c21ec6d108313080ccf8bdf2212ce52ad80bbb5.tar.xz |
reverting #7295, as it still fails a test case (as pointed out very
kindly by sean) --- lesson learned: just running a "make test" is not
sufficient, you need to precede it by a "make clean".
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.Inventory.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index 590bea0..12095e5 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |||
@@ -1179,8 +1179,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
1179 | destTaskItem.InvType = srcTaskItem.InvType; | 1179 | destTaskItem.InvType = srcTaskItem.InvType; |
1180 | destTaskItem.Type = srcTaskItem.Type; | 1180 | destTaskItem.Type = srcTaskItem.Type; |
1181 | 1181 | ||
1182 | destPart.AddInventoryItem(destTaskItem, part.OwnerID!=destPart.OwnerID | 1182 | destPart.AddInventoryItem(destTaskItem); |
1183 | && ExternalChecks.ExternalChecksPropagatePermissions()); | ||
1184 | 1183 | ||
1185 | if ((srcTaskItem.CurrentPermissions & (uint)PermissionMask.Copy) == 0) | 1184 | if ((srcTaskItem.CurrentPermissions & (uint)PermissionMask.Copy) == 0) |
1186 | part.RemoveInventoryItem(itemId); | 1185 | part.RemoveInventoryItem(itemId); |
@@ -1250,16 +1249,11 @@ namespace OpenSim.Region.Environment.Scenes | |||
1250 | 1249 | ||
1251 | if (part != null) | 1250 | if (part != null) |
1252 | { | 1251 | { |
1253 | TaskInventoryItem currentItem = part.GetInventoryItem(itemID); | 1252 | if (!ExternalChecks.ExternalChecksCanEditObjectInventory(part.UUID, remoteClient.AgentId)) |
1254 | bool allowInventoryDrop = (part.GetEffectiveObjectFlags() | ||
1255 | & (uint)PrimFlags.AllowInventoryDrop) != 0; | ||
1256 | // Explicity allow anyone to add to the inventory if the AllowInventoryDrop | ||
1257 | // flag has been set. Don't however let them update an item unless | ||
1258 | // they pass the external checks | ||
1259 | if (!ExternalChecks.ExternalChecksCanEditObjectInventory(part.UUID, remoteClient.AgentId) | ||
1260 | && (currentItem != null || !allowInventoryDrop )) | ||
1261 | return; | 1253 | return; |
1262 | 1254 | ||
1255 | TaskInventoryItem currentItem = part.GetInventoryItem(itemID); | ||
1256 | |||
1263 | if (currentItem == null) | 1257 | if (currentItem == null) |
1264 | { | 1258 | { |
1265 | UUID copyID = UUID.Random(); | 1259 | UUID copyID = UUID.Random(); |
@@ -1423,7 +1417,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
1423 | taskItem.PermsMask = 0; | 1417 | taskItem.PermsMask = 0; |
1424 | taskItem.AssetID = asset.FullID; | 1418 | taskItem.AssetID = asset.FullID; |
1425 | 1419 | ||
1426 | part.AddInventoryItem(taskItem, false); | 1420 | part.AddInventoryItem(taskItem); |
1427 | part.GetProperties(remoteClient); | 1421 | part.GetProperties(remoteClient); |
1428 | 1422 | ||
1429 | part.CreateScriptInstance(taskItem, 0, false, DefaultScriptEngine, 0); | 1423 | part.CreateScriptInstance(taskItem, 0, false, DefaultScriptEngine, 0); |
@@ -1518,7 +1512,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
1518 | destTaskItem.InvType = srcTaskItem.InvType; | 1512 | destTaskItem.InvType = srcTaskItem.InvType; |
1519 | destTaskItem.Type = srcTaskItem.Type; | 1513 | destTaskItem.Type = srcTaskItem.Type; |
1520 | 1514 | ||
1521 | destPart.AddInventoryItemExclusive(destTaskItem, false); | 1515 | destPart.AddInventoryItemExclusive(destTaskItem); |
1522 | 1516 | ||
1523 | if (running > 0) | 1517 | if (running > 0) |
1524 | { | 1518 | { |