On IAR loading, if loading of a coaleseced item entirely fails, then continue with the IAR load rather than failing completely.

user_profiles
Justin Clark-Casey (justincc) 2013-02-08 02:34:13 +00:00
parent e836da5d20
commit 221a90e3a1
1 changed files with 18 additions and 0 deletions

View File

@ -488,6 +488,14 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
// m_log.DebugFormat( // m_log.DebugFormat(
// "[INVENTORY ARCHIVER]: Loaded coalescence {0} has {1} objects", assetId, coa.Count); // "[INVENTORY ARCHIVER]: Loaded coalescence {0} has {1} objects", assetId, coa.Count);
if (coa.Objects.Count == 0)
{
m_log.WarnFormat(
"[INVENTORY ARCHIVE READ REQUEST]: Aborting load of coalesced object from asset {0} as it has zero loaded components",
assetId);
return false;
}
sceneObjects.AddRange(coa.Objects); sceneObjects.AddRange(coa.Objects);
} }
else else
@ -495,8 +503,18 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
SceneObjectGroup deserializedObject = SceneObjectSerializer.FromOriginalXmlFormat(xmlData); SceneObjectGroup deserializedObject = SceneObjectSerializer.FromOriginalXmlFormat(xmlData);
if (deserializedObject != null) if (deserializedObject != null)
{
sceneObjects.Add(deserializedObject); sceneObjects.Add(deserializedObject);
} }
else
{
m_log.WarnFormat(
"[INVENTORY ARCHIVE READ REQUEST]: Aborting load of object from asset {0} as deserialization failed",
assetId);
return false;
}
}
foreach (SceneObjectGroup sog in sceneObjects) foreach (SceneObjectGroup sog in sceneObjects)
foreach (SceneObjectPart sop in sog.Parts) foreach (SceneObjectPart sop in sog.Parts)