aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/ClientManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/ClientManager.cs')
-rw-r--r--OpenSim/Framework/ClientManager.cs23
1 files changed, 9 insertions, 14 deletions
diff --git a/OpenSim/Framework/ClientManager.cs b/OpenSim/Framework/ClientManager.cs
index fd5f87f..367bc6a 100644
--- a/OpenSim/Framework/ClientManager.cs
+++ b/OpenSim/Framework/ClientManager.cs
@@ -121,20 +121,10 @@ namespace OpenSim.Framework
121 /// <summary> 121 /// <summary>
122 /// Remove a client from the collection 122 /// Remove a client from the collection
123 /// </summary> 123 /// </summary>
124 /// <param name="value">Reference to the client object</param> 124 /// <param name="key">UUID of the client to remove</param>
125 public void Remove(IClientAPI value) 125 /// <returns>True if a client was removed, or false if the given UUID
126 { 126 /// was not present in the collection</returns>
127 lock (m_writeLock) 127 public bool Remove(UUID key)
128 {
129 if (m_dict.ContainsKey(value.AgentId))
130 m_dict = m_dict.Delete(value.AgentId);
131
132 if (m_dict2.ContainsKey(value.RemoteEndPoint))
133 m_dict2 = m_dict2.Delete(value.RemoteEndPoint);
134 }
135 }
136
137 public void Remove(UUID key)
138 { 128 {
139 lock (m_writeLock) 129 lock (m_writeLock)
140 { 130 {
@@ -144,6 +134,11 @@ namespace OpenSim.Framework
144 { 134 {
145 m_dict = m_dict.Delete(key); 135 m_dict = m_dict.Delete(key);
146 m_dict2 = m_dict2.Delete(client.RemoteEndPoint); 136 m_dict2 = m_dict2.Delete(client.RemoteEndPoint);
137 return true;
138 }
139 else
140 {
141 return false;
147 } 142 }
148 } 143 }
149 } 144 }