aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack
diff options
context:
space:
mode:
authordahlia2013-07-16 01:31:09 -0700
committerdahlia2013-07-16 01:31:09 -0700
commit70aa77f520060a27df1fb7fbdf39685ff866dcf8 (patch)
tree01a65ddedd5a906cd2b9eafb7de775f07fbced93 /OpenSim/Region/ClientStack
parentMSDN documentation is unclear about whether exiting a lock() block will trigg... (diff)
downloadopensim-SC_OLD-70aa77f520060a27df1fb7fbdf39685ff866dcf8.zip
opensim-SC_OLD-70aa77f520060a27df1fb7fbdf39685ff866dcf8.tar.gz
opensim-SC_OLD-70aa77f520060a27df1fb7fbdf39685ff866dcf8.tar.bz2
opensim-SC_OLD-70aa77f520060a27df1fb7fbdf39685ff866dcf8.tar.xz
add locking to internal queue in WebFetchInvDescModule; lack of which caused a random crash in a load test yesterday
Diffstat (limited to 'OpenSim/Region/ClientStack')
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs15
1 files changed, 10 insertions, 5 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs b/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs
index 164adeb..4ff617f 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs
@@ -254,10 +254,13 @@ namespace OpenSim.Region.ClientStack.Linden
254 } 254 }
255 } 255 }
256 256
257 if (highPriority) 257 lock (m_queue)
258 m_queue.EnqueueHigh(reqinfo); 258 {
259 else 259 if (highPriority)
260 m_queue.EnqueueLow(reqinfo); 260 m_queue.EnqueueHigh(reqinfo);
261 else
262 m_queue.EnqueueLow(reqinfo);
263 }
261 }; 264 };
262 265
263 NoEvents = (x, y) => 266 NoEvents = (x, y) =>
@@ -345,7 +348,9 @@ namespace OpenSim.Region.ClientStack.Linden
345 { 348 {
346 Watchdog.UpdateThread(); 349 Watchdog.UpdateThread();
347 350
348 aPollRequest poolreq = m_queue.Dequeue(); 351 aPollRequest poolreq = null;
352 lock (m_queue)
353 poolreq = m_queue.Dequeue();
349 354
350 if (poolreq != null && poolreq.thepoll != null) 355 if (poolreq != null && poolreq.thepoll != null)
351 poolreq.thepoll.Process(poolreq); 356 poolreq.thepoll.Process(poolreq);