Only look for an uploaded transactional asset in Scene.UpdateTaskInventory if we have been passed a non-zero transaction ID.
This resolves the recent regression from0.7.2-post-fixesdeeb728
where notecards could not be saved in prim inventories. This looks like a better solution thandeeb728
since only non-caps updates pass in a transaction ID. Hopefully resolves http://opensimulator.org/mantis/view.php?id=5873
parent
31a0f75aff
commit
2030377d2c
|
@ -1450,26 +1450,25 @@ namespace OpenSim.Region.Framework.Scenes
|
|||
// "[PRIM INVENTORY]: Updating item {0} in {1} for UpdateTaskInventory()",
|
||||
// currentItem.Name, part.Name);
|
||||
|
||||
// Viewers from at least Linden Lab 1.23 onwards use a capability to update script contents rather
|
||||
// than UDP. With viewers from at least 1.23 onwards, changing properties on scripts (e.g. renaming) causes
|
||||
// this to spew spurious errors and "thing saved" messages.
|
||||
// Rather than retaining complexity in the code and removing useful error messages, I'm going to
|
||||
// comment this section out. If this was still working for very old viewers and there is
|
||||
// a large population using them which cannot upgrade to 1.23 or derivatives then we can revisit
|
||||
// this - justincc
|
||||
// IAgentAssetTransactions agentTransactions = this.RequestModuleInterface<IAgentAssetTransactions>();
|
||||
// if (agentTransactions != null)
|
||||
// {
|
||||
// agentTransactions.HandleTaskItemUpdateFromTransaction(
|
||||
// remoteClient, part, transactionID, currentItem);
|
||||
//
|
||||
// if ((InventoryType)itemInfo.InvType == InventoryType.Notecard)
|
||||
// remoteClient.SendAgentAlertMessage("Notecard saved", false);
|
||||
// else if ((InventoryType)itemInfo.InvType == InventoryType.LSL)
|
||||
// remoteClient.SendAgentAlertMessage("Script saved", false);
|
||||
// else
|
||||
// remoteClient.SendAgentAlertMessage("Item saved", false);
|
||||
// }
|
||||
// Only look for an uploaded updated asset if we are passed a transaction ID. This is only the
|
||||
// case for updates uploded through UDP. Updates uploaded via a capability (e.g. a script update)
|
||||
// will not pass in a transaction ID in the update message.
|
||||
if (transactionID != UUID.Zero)
|
||||
{
|
||||
IAgentAssetTransactions agentTransactions = this.RequestModuleInterface<IAgentAssetTransactions>();
|
||||
if (agentTransactions != null)
|
||||
{
|
||||
agentTransactions.HandleTaskItemUpdateFromTransaction(
|
||||
remoteClient, part, transactionID, currentItem);
|
||||
|
||||
if ((InventoryType)itemInfo.InvType == InventoryType.Notecard)
|
||||
remoteClient.SendAgentAlertMessage("Notecard saved", false);
|
||||
else if ((InventoryType)itemInfo.InvType == InventoryType.LSL)
|
||||
remoteClient.SendAgentAlertMessage("Script saved", false);
|
||||
else
|
||||
remoteClient.SendAgentAlertMessage("Item saved", false);
|
||||
}
|
||||
}
|
||||
|
||||
// Base ALWAYS has move
|
||||
currentItem.BasePermissions |= (uint)PermissionMask.Move;
|
||||
|
|
|
@ -122,7 +122,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
|
|||
TestHelpers.InMethod();
|
||||
// log4net.Config.XmlConfigurator.Configure();
|
||||
|
||||
UUID agent1Id = UUID.Parse("00000000-0000-0000-0000-000000000001");
|
||||
// UUID agent1Id = UUID.Parse("00000000-0000-0000-0000-000000000001");
|
||||
|
||||
TestScene myScene1 = SceneHelpers.SetupScene("Neighbour y", UUID.Random(), 1000, 1000);
|
||||
// TestScene myScene2 = SceneHelpers.SetupScene("Neighbour y + 1", UUID.Random(), 1001, 1000);
|
||||
|
|
Loading…
Reference in New Issue