Prevent sending of attachment data to any client if the attachment

is not actually attached to any avatar. Another stab ad fixing "HUD hair"
avinationmerge
Melanie 2010-12-08 00:08:14 +01:00
parent 1e7b7ffd6b
commit 80b84e4bad
1 changed files with 21 additions and 0 deletions

View File

@ -3615,6 +3615,27 @@ namespace OpenSim.Region.ClientStack.LindenUDP
if (part.ParentGroup.OwnerID != AgentId && if (part.ParentGroup.OwnerID != AgentId &&
part.ParentGroup.RootPart.Shape.State >= 30) part.ParentGroup.RootPart.Shape.State >= 30)
continue; continue;
ScenePresence sp;
// Owner is not in the sim, don't update it to
// anyone
if (!m_scene.TryGetScenePresence(part.OwnerID, out sp))
continue;
List<SceneObjectGroup> atts = sp.Attachments;
bool found = false;
foreach (SceneObjectGroup att in atts)
{
if (att == part.ParentGroup)
{
found = true;
break;
}
}
// It's an attachment of a valid avatar, but
// doesn't seem to be attached, skip
if (!found)
continue;
} }
if (part.ParentGroup.IsAttachment && m_disableFacelights) if (part.ParentGroup.IsAttachment && m_disableFacelights)