From 712c50e0bf2a70e5b7d950113191b20af4fec429 Mon Sep 17 00:00:00 2001 From: Oren Hurvitz Date: Fri, 18 Jul 2014 17:39:20 +0300 Subject: [PATCH] Don't append attachments multiple times --- OpenSim/Framework/AvatarAppearance.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/OpenSim/Framework/AvatarAppearance.cs b/OpenSim/Framework/AvatarAppearance.cs index b7a0adface..69113b1d9c 100644 --- a/OpenSim/Framework/AvatarAppearance.cs +++ b/OpenSim/Framework/AvatarAppearance.cs @@ -520,6 +520,12 @@ namespace OpenSim.Framework if (!m_attachments.ContainsKey(attach.AttachPoint)) m_attachments[attach.AttachPoint] = new List(); + foreach (AvatarAttachment prev in m_attachments[attach.AttachPoint]) + { + if (prev.ItemID == attach.ItemID) + return; + } + m_attachments[attach.AttachPoint].Add(attach); } }