aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-12-03 16:11:47 +0000
committerJustin Clark-Casey (justincc)2011-12-03 16:11:47 +0000
commitc934901a056f142c49e6b449971fcaf59ff19d82 (patch)
treed3376fd8c5ff665dc3045f68250b6b9fe547a53a /OpenSim/Region
parentAdd agent circuit number checks to TestCloseAgent() (diff)
downloadopensim-SC_OLD-c934901a056f142c49e6b449971fcaf59ff19d82.zip
opensim-SC_OLD-c934901a056f142c49e6b449971fcaf59ff19d82.tar.gz
opensim-SC_OLD-c934901a056f142c49e6b449971fcaf59ff19d82.tar.bz2
opensim-SC_OLD-c934901a056f142c49e6b449971fcaf59ff19d82.tar.xz
Use GetAgentCircuits() to receive a copy of the AgentCircuitsByUUID dictionary rather than AgentCircuitManager.AgentCircuits directly in "show circuits" to avoid enumeration exceptions
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/Application/OpenSim.cs2
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/ScenePresenceAgentTests.cs6
2 files changed, 3 insertions, 5 deletions
diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs
index 4b38a2e..8d98cc9 100644
--- a/OpenSim/Region/Application/OpenSim.cs
+++ b/OpenSim/Region/Application/OpenSim.cs
@@ -1039,7 +1039,7 @@ namespace OpenSim
1039 { 1039 {
1040 //this.HttpServer. 1040 //this.HttpServer.
1041 acd.AppendFormat("{0}:\n", scene.RegionInfo.RegionName); 1041 acd.AppendFormat("{0}:\n", scene.RegionInfo.RegionName);
1042 foreach (AgentCircuitData aCircuit in scene.AuthenticateHandler.AgentCircuits.Values) 1042 foreach (AgentCircuitData aCircuit in scene.AuthenticateHandler.GetAgentCircuits().Values)
1043 acd.AppendFormat("\t{0} {1} ({2})\n", aCircuit.firstname, aCircuit.lastname, (aCircuit.child ? "Child" : "Root")); 1043 acd.AppendFormat("\t{0} {1} ({2})\n", aCircuit.firstname, aCircuit.lastname, (aCircuit.child ? "Child" : "Root"));
1044 } 1044 }
1045 ); 1045 );
diff --git a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceAgentTests.cs b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceAgentTests.cs
index f6a3d1f..57d22bd 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceAgentTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceAgentTests.cs
@@ -103,15 +103,13 @@ namespace OpenSim.Region.Framework.Scenes.Tests
103 ScenePresence sp = SceneHelpers.AddScenePresence(scene, TestHelpers.ParseTail(0x1)); 103 ScenePresence sp = SceneHelpers.AddScenePresence(scene, TestHelpers.ParseTail(0x1));
104 104
105 Assert.That(scene.AuthenticateHandler.GetAgentCircuitData(sp.UUID), Is.Not.Null); 105 Assert.That(scene.AuthenticateHandler.GetAgentCircuitData(sp.UUID), Is.Not.Null);
106 Assert.That(scene.AuthenticateHandler.AgentCircuits.Count, Is.EqualTo(1)); 106 Assert.That(scene.AuthenticateHandler.GetAgentCircuits().Count, Is.EqualTo(1));
107 Assert.That(scene.AuthenticateHandler.AgentCircuitsByUUID.Count, Is.EqualTo(1));
108 107
109 scene.IncomingCloseAgent(sp.UUID); 108 scene.IncomingCloseAgent(sp.UUID);
110 109
111 Assert.That(scene.GetScenePresence(sp.UUID), Is.Null); 110 Assert.That(scene.GetScenePresence(sp.UUID), Is.Null);
112 Assert.That(scene.AuthenticateHandler.GetAgentCircuitData(sp.UUID), Is.Null); 111 Assert.That(scene.AuthenticateHandler.GetAgentCircuitData(sp.UUID), Is.Null);
113 Assert.That(scene.AuthenticateHandler.AgentCircuits.Count, Is.EqualTo(0)); 112 Assert.That(scene.AuthenticateHandler.GetAgentCircuits().Count, Is.EqualTo(0));
114 Assert.That(scene.AuthenticateHandler.AgentCircuitsByUUID.Count, Is.EqualTo(0));
115 } 113 }
116 114
117 /// <summary> 115 /// <summary>