Addresses mantis #4984 -- Datasnapshot exceptions.

0.7.0.2-release
Diva Canto 2010-08-26 12:26:09 -07:00
parent 97807d77a1
commit 735124bece
1 changed files with 12 additions and 3 deletions

View File

@ -142,9 +142,18 @@ namespace OpenSim.Region.DataSnapshot.Providers
node.InnerText = m_scene.RegionInfo.RegionSettings.RegionUUID.ToString(); node.InnerText = m_scene.RegionInfo.RegionSettings.RegionUUID.ToString();
xmlobject.AppendChild(node); xmlobject.AppendChild(node);
node = nodeFactory.CreateNode(XmlNodeType.Element, "parceluuid", ""); if (land != null && land.LandData != null)
node.InnerText = land.LandData.GlobalID.ToString(); {
xmlobject.AppendChild(node); node = nodeFactory.CreateNode(XmlNodeType.Element, "parceluuid", "");
node.InnerText = land.LandData.GlobalID.ToString();
xmlobject.AppendChild(node);
}
else
{
// Something is wrong with this object. Let's not list it.
m_log.WarnFormat("[DATASNAPSHOT]: Bad data for object {0} ({1}) in region {2}", obj.Name, obj.UUID, m_scene.RegionInfo.RegionName);
continue;
}
node = nodeFactory.CreateNode(XmlNodeType.Element, "location", ""); node = nodeFactory.CreateNode(XmlNodeType.Element, "location", "");
Vector3 loc = obj.AbsolutePosition; Vector3 loc = obj.AbsolutePosition;