diff options
author | CasperW | 2009-12-06 17:23:07 +0100 |
---|---|---|
committer | CasperW | 2009-12-06 17:23:07 +0100 |
commit | 172e2f4e7609c278d02ad83ca207fd79624db587 (patch) | |
tree | 37c6d737e3fb8b3611efd4fa5dbaf38572128e51 /OpenSim/Framework | |
parent | Change EntityManager to use RWlocks (diff) | |
download | opensim-SC-172e2f4e7609c278d02ad83ca207fd79624db587.zip opensim-SC-172e2f4e7609c278d02ad83ca207fd79624db587.tar.gz opensim-SC-172e2f4e7609c278d02ad83ca207fd79624db587.tar.bz2 opensim-SC-172e2f4e7609c278d02ad83ca207fd79624db587.tar.xz |
Fix to existing ReaderWriterLockSlim implementations
Diffstat (limited to 'OpenSim/Framework')
-rw-r--r-- | OpenSim/Framework/TaskInventoryDictionary.cs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/OpenSim/Framework/TaskInventoryDictionary.cs b/OpenSim/Framework/TaskInventoryDictionary.cs index efe5f0c..4b9a509 100644 --- a/OpenSim/Framework/TaskInventoryDictionary.cs +++ b/OpenSim/Framework/TaskInventoryDictionary.cs | |||
@@ -109,7 +109,10 @@ namespace OpenSim.Framework | |||
109 | } | 109 | } |
110 | else | 110 | else |
111 | { | 111 | { |
112 | m_itemLock.ExitReadLock(); | 112 | if (m_itemLock.RecursiveReadCount>0) |
113 | { | ||
114 | m_itemLock.ExitReadLock(); | ||
115 | } | ||
113 | } | 116 | } |
114 | } | 117 | } |
115 | 118 | ||
@@ -144,7 +147,10 @@ namespace OpenSim.Framework | |||
144 | } | 147 | } |
145 | else | 148 | else |
146 | { | 149 | { |
147 | m_itemLock.ExitWriteLock(); | 150 | if (m_itemLock.RecursiveWriteCount > 0) |
151 | { | ||
152 | m_itemLock.ExitWriteLock(); | ||
153 | } | ||
148 | } | 154 | } |
149 | } | 155 | } |
150 | 156 | ||