* minor: Stop spurious 'item not found' messages when placing things into a prim's inventory
parent
f6375fceb4
commit
0b16f9eee2
|
@ -239,8 +239,14 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
// Retrieve item
|
// Retrieve item
|
||||||
TaskInventoryItem item = group.GetInventoryItem(part.LocalId, itemId);
|
TaskInventoryItem item = group.GetInventoryItem(part.LocalId, itemId);
|
||||||
|
|
||||||
if (null == item)
|
if (null == item)
|
||||||
{
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[PRIM INVENTORY]: Tried to retrieve item ID {0} from prim {1}, {2} for caps script update "
|
||||||
|
+ " but the item does not exist in this inventory",
|
||||||
|
itemId, part.Name, part.UUID);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -878,7 +884,12 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
if (null == taskItem)
|
if (null == taskItem)
|
||||||
{
|
{
|
||||||
// Console already notified of error in GetInventoryItem
|
m_log.ErrorFormat(
|
||||||
|
"[PRIM INVENTORY]: Tried to retrieve item ID {0} from prim {1}, {2} for creating an avatar"
|
||||||
|
+ " inventory item from a prim's inventory item "
|
||||||
|
+ " but the required item does not exist in the prim's inventory",
|
||||||
|
itemId, part.Name, part.UUID);
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1010,7 +1021,11 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
if (srcTaskItem == null)
|
if (srcTaskItem == null)
|
||||||
{
|
{
|
||||||
// error was already logged
|
m_log.ErrorFormat(
|
||||||
|
"[PRIM INVENTORY]: Tried to retrieve item ID {0} from prim {1}, {2} for moving"
|
||||||
|
+ " but the item does not exist in this inventory",
|
||||||
|
itemId, part.Name, part.UUID);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1143,7 +1158,8 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
if (part != null)
|
if (part != null)
|
||||||
{
|
{
|
||||||
TaskInventoryItem currentItem=part.GetInventoryItem(itemID);
|
TaskInventoryItem currentItem = part.GetInventoryItem(itemID);
|
||||||
|
|
||||||
if (currentItem == null)
|
if (currentItem == null)
|
||||||
{
|
{
|
||||||
LLUUID copyID = LLUUID.Random();
|
LLUUID copyID = LLUUID.Random();
|
||||||
|
@ -1186,7 +1202,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
}
|
}
|
||||||
else // Updating existing item with new perms etc
|
else // Updating existing item with new perms etc
|
||||||
{
|
{
|
||||||
TaskInventoryItem prevItem=part.GetInventoryItem(itemID);
|
TaskInventoryItem prevItem = part.GetInventoryItem(itemID);
|
||||||
itemInfo.AssetID = prevItem.AssetID;
|
itemInfo.AssetID = prevItem.AssetID;
|
||||||
if (part.UpdateInventoryItem(itemInfo))
|
if (part.UpdateInventoryItem(itemInfo))
|
||||||
part.GetProperties(remoteClient);
|
part.GetProperties(remoteClient);
|
||||||
|
@ -1314,7 +1330,11 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
if (srcTaskItem == null)
|
if (srcTaskItem == null)
|
||||||
{
|
{
|
||||||
// error was already logged
|
m_log.ErrorFormat(
|
||||||
|
"[PRIM INVENTORY]: Tried to retrieve item ID {0} from prim {1}, {2} for rezzing a script but the "
|
||||||
|
+ " item does not exist in this inventory",
|
||||||
|
srcId, srcPart.Name, srcPart.UUID);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -272,7 +272,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
item.ParentID = UUID;
|
item.ParentID = UUID;
|
||||||
item.ParentPartID = UUID;
|
item.ParentPartID = UUID;
|
||||||
|
|
||||||
string name=FindAvailableInventoryName(item.Name);
|
string name = FindAvailableInventoryName(item.Name);
|
||||||
if (name == String.Empty)
|
if (name == String.Empty)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -346,7 +346,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
/// <param name="itemID"></param>
|
/// <param name="itemID"></param>
|
||||||
/// <returns>null if the item does not exist</returns>
|
/// <returns>null if the item does not exist</returns>
|
||||||
public TaskInventoryItem GetInventoryItem(LLUUID itemID)
|
public TaskInventoryItem GetInventoryItem(LLUUID itemID)
|
||||||
{
|
{
|
||||||
lock (m_taskInventory)
|
lock (m_taskInventory)
|
||||||
{
|
{
|
||||||
if (m_taskInventory.ContainsKey(itemID))
|
if (m_taskInventory.ContainsKey(itemID))
|
||||||
|
@ -357,13 +357,6 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
return m_taskInventory[itemID];
|
return m_taskInventory[itemID];
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
m_log.ErrorFormat(
|
|
||||||
"[PRIM INVENTORY]: " +
|
|
||||||
"Tried to retrieve item ID {0} from prim {1}, {2} but the item does not exist in this inventory",
|
|
||||||
itemID, Name, UUID);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
|
|
Loading…
Reference in New Issue