diff options
Diffstat (limited to 'OpenSim/Region/Environment')
-rw-r--r-- | OpenSim/Region/Environment/Modules/World/WorldMap/WorldMapModule.cs | 48 |
1 files changed, 28 insertions, 20 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/Environment/Modules/World/WorldMap/WorldMapModule.cs index b6c36f8..b277626 100644 --- a/OpenSim/Region/Environment/Modules/World/WorldMap/WorldMapModule.cs +++ b/OpenSim/Region/Environment/Modules/World/WorldMap/WorldMapModule.cs | |||
@@ -390,32 +390,40 @@ namespace OpenSim.Region.Environment.Modules.World.WorldMap | |||
390 | /// </summary> | 390 | /// </summary> |
391 | public void process() | 391 | public void process() |
392 | { | 392 | { |
393 | while (true) | 393 | try |
394 | { | 394 | { |
395 | MapRequestState st = requests.Dequeue(); | 395 | while (true) |
396 | |||
397 | // end gracefully | ||
398 | if (st.agentID == UUID.Zero) | ||
399 | { | ||
400 | ThreadTracker.Remove(mapItemReqThread); | ||
401 | break; | ||
402 | } | ||
403 | |||
404 | bool dorequest = true; | ||
405 | lock (m_rootAgents) | ||
406 | { | 396 | { |
407 | if (!m_rootAgents.Contains(st.agentID)) | 397 | MapRequestState st = requests.Dequeue(); |
408 | dorequest = false; | 398 | |
409 | } | 399 | // end gracefully |
400 | if (st.agentID == UUID.Zero) | ||
401 | { | ||
402 | ThreadTracker.Remove(mapItemReqThread); | ||
403 | break; | ||
404 | } | ||
405 | |||
406 | bool dorequest = true; | ||
407 | lock (m_rootAgents) | ||
408 | { | ||
409 | if (!m_rootAgents.Contains(st.agentID)) | ||
410 | dorequest = false; | ||
411 | } | ||
410 | 412 | ||
411 | if (dorequest) | 413 | if (dorequest) |
412 | { | 414 | { |
413 | LLSDMap response = RequestMapItemsAsync("", st.agentID, st.flags, st.EstateID, st.godlike, st.itemtype, st.regionhandle); | 415 | LLSDMap response = RequestMapItemsAsync("", st.agentID, st.flags, st.EstateID, st.godlike, st.itemtype, st.regionhandle); |
414 | RequestMapItemsCompleted(response); | 416 | RequestMapItemsCompleted(response); |
417 | } | ||
415 | } | 418 | } |
416 | } | 419 | } |
420 | catch (Exception e) | ||
421 | { | ||
422 | m_log.ErrorFormat("[WorldMap]: Map item request thread terminated abnormally with exception {0}", e); | ||
423 | } | ||
424 | |||
417 | threadrunning = false; | 425 | threadrunning = false; |
418 | m_log.Warn("[WorldMap]: Remote request thread exiting"); | 426 | m_log.Debug("[WorldMap]: Remote request thread exiting"); |
419 | } | 427 | } |
420 | 428 | ||
421 | /// <summary> | 429 | /// <summary> |