aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorJustin Clarke Casey2008-07-11 17:58:26 +0000
committerJustin Clarke Casey2008-07-11 17:58:26 +0000
commitda68f18a6be3836e573dab7ff08e2ae7f90e2608 (patch)
treeb844f5ae066c22a737b971f2b333c5d34a3e3a84 /OpenSim
parentPatch #9140 (Mantis #1683) (diff)
downloadopensim-SC-da68f18a6be3836e573dab7ff08e2ae7f90e2608.zip
opensim-SC-da68f18a6be3836e573dab7ff08e2ae7f90e2608.tar.gz
opensim-SC-da68f18a6be3836e573dab7ff08e2ae7f90e2608.tar.bz2
opensim-SC-da68f18a6be3836e573dab7ff08e2ae7f90e2608.tar.xz
* Guard against a null point passed to RemoveClientCircuit (odd that this happens at all)
* Patch from Kurt Taylor (IBM) in http://opensimulator.org/mantis/view.php?id=1720 * Thanks Kurt!
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs19
1 files changed, 15 insertions, 4 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
index d705ef2..570ebe9 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
@@ -474,15 +474,26 @@ namespace OpenSim.Region.ClientStack.LindenUDP
474 public virtual void RemoveClientCircuit(uint circuitcode) 474 public virtual void RemoveClientCircuit(uint circuitcode)
475 { 475 {
476 EndPoint sendto = null; 476 EndPoint sendto = null;
477 if (clientCircuits_reverse.Contains(circuitcode)) { 477 if (clientCircuits_reverse.Contains(circuitcode))
478 {
478 sendto = (EndPoint)clientCircuits_reverse[circuitcode]; 479 sendto = (EndPoint)clientCircuits_reverse[circuitcode];
479 480
480 clientCircuits_reverse.Remove(circuitcode); 481 clientCircuits_reverse.Remove(circuitcode);
481 482
482 lock (clientCircuits) { 483 lock (clientCircuits)
483 clientCircuits.Remove(sendto); 484 {
485 if (sendto != null)
486 {
487 clientCircuits.Remove(sendto);
488 }
489 else
490 {
491 m_log.DebugFormat(
492 "[UDPSERVER]: endpoint for circuit code {0} in RemoveClientCircuit() was unexpectedly null!", circuitcode);
493 }
484 } 494 }
485 lock (proxyCircuits) { 495 lock (proxyCircuits)
496 {
486 proxyCircuits.Remove(circuitcode); 497 proxyCircuits.Remove(circuitcode);
487 } 498 }
488 } 499 }