Ensure the specified imSessionID exists in the DroppedSession collection before attempting to access it.

0.6.8-post-fixes
Michael Cortez 2009-10-05 11:59:33 -07:00 committed by Melanie
parent 8d7075c5c6
commit 90d1ef9e4a
1 changed files with 1 additions and 1 deletions

View File

@ -425,7 +425,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups
foreach (GroupMembersData member in m_groupsModule.GroupMembersRequest(null, groupID)) foreach (GroupMembersData member in m_groupsModule.GroupMembersRequest(null, groupID))
{ {
if (m_agentsDroppedSession[im.imSessionID].Contains(member.AgentID.Guid)) if (!m_agentsDroppedSession.ContainsKey(im.imSessionID) || m_agentsDroppedSession[im.imSessionID].Contains(member.AgentID.Guid))
{ {
// Don't deliver messages to people who have dropped this session // Don't deliver messages to people who have dropped this session
if (m_debugEnabled) m_log.DebugFormat("[GROUPS-MESSAGING]: {0} has dropped session, not delivering to them", member.AgentID); if (m_debugEnabled) m_log.DebugFormat("[GROUPS-MESSAGING]: {0} has dropped session, not delivering to them", member.AgentID);