From 3f78ff6ee0837c0179be5f43d485d9ca23ee454b Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Fri, 9 Oct 2009 19:16:03 -0700 Subject: Slight variation on the locking scheme: now locking always, except the ForEach, which gets a copy of the Array. I think the ForEach was the big gorilla. --- .../ClientStack/LindenUDP/LLUDPClientCollection.cs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLUDPClientCollection.cs b/OpenSim/Region/ClientStack/LindenUDP/LLUDPClientCollection.cs index 784426f..dbb9861 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLUDPClientCollection.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLUDPClientCollection.cs @@ -247,16 +247,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP ////return success; - //lock (m_sync) - // return Dictionary2.TryGetValue(key, out value); - - try - { + lock (m_sync) return Dictionary2.TryGetValue(key, out value); - } - catch { } - value = null; - return false; + + //try + //{ + // return Dictionary2.TryGetValue(key, out value); + //} + //catch { } + //value = null; + //return false; } -- cgit v1.1