diff options
author | Diva Canto | 2013-08-09 08:31:30 -0700 |
---|---|---|
committer | Diva Canto | 2013-08-09 08:31:30 -0700 |
commit | 2cdcf62b48fde64d1ad11a4db46afeddff1a0770 (patch) | |
tree | 76d2f53def5e6cd05b9b9e5f3e3e1e759c29e87e /OpenSim/Region/Framework/Scenes/Scene.cs | |
parent | Go easy on enforcing session ids in position updates (diff) | |
parent | BulletSim: adjust avatar position when the avatar's size is changed. (diff) | |
download | opensim-SC-2cdcf62b48fde64d1ad11a4db46afeddff1a0770.zip opensim-SC-2cdcf62b48fde64d1ad11a4db46afeddff1a0770.tar.gz opensim-SC-2cdcf62b48fde64d1ad11a4db46afeddff1a0770.tar.bz2 opensim-SC-2cdcf62b48fde64d1ad11a4db46afeddff1a0770.tar.xz |
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Scene.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 1633e07..b97a0f6 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -4222,36 +4222,42 @@ namespace OpenSim.Region.Framework.Scenes | |||
4222 | } | 4222 | } |
4223 | 4223 | ||
4224 | // We have to wait until the viewer contacts this region | 4224 | // We have to wait until the viewer contacts this region |
4225 | // after receiving the EnableSimulator HTTP Event Queue message. This triggers the viewer to send | 4225 | // after receiving the EnableSimulator HTTP Event Queue message (for the v1 teleport protocol) |
4226 | // or TeleportFinish (for the v2 teleport protocol). This triggers the viewer to send | ||
4226 | // a UseCircuitCode packet which in turn calls AddNewClient which finally creates the ScenePresence. | 4227 | // a UseCircuitCode packet which in turn calls AddNewClient which finally creates the ScenePresence. |
4227 | ScenePresence childAgentUpdate = WaitGetScenePresence(cAgentData.AgentID); | 4228 | ScenePresence sp = WaitGetScenePresence(cAgentData.AgentID); |
4228 | 4229 | ||
4229 | if (childAgentUpdate != null) | 4230 | if (sp != null) |
4230 | { | 4231 | { |
4231 | if (cAgentData.SessionID != childAgentUpdate.ControllingClient.SessionId) | 4232 | if (cAgentData.SessionID != sp.ControllingClient.SessionId) |
4232 | { | 4233 | { |
4233 | m_log.WarnFormat("[SCENE]: Attempt to update agent {0} with invalid session id {1} (possibly from simulator in older version; tell them to update).", childAgentUpdate.UUID, cAgentData.SessionID); | 4234 | m_log.WarnFormat( |
4235 | "[SCENE]: Attempt to update agent {0} with invalid session id {1} (possibly from simulator in older version; tell them to update).", | ||
4236 | sp.UUID, cAgentData.SessionID); | ||
4237 | |||
4234 | Console.WriteLine(String.Format("[SCENE]: Attempt to update agent {0} ({1}) with invalid session id {2}", | 4238 | Console.WriteLine(String.Format("[SCENE]: Attempt to update agent {0} ({1}) with invalid session id {2}", |
4235 | childAgentUpdate.UUID, childAgentUpdate.ControllingClient.SessionId, cAgentData.SessionID)); | 4239 | sp.UUID, sp.ControllingClient.SessionId, cAgentData.SessionID)); |
4236 | } | 4240 | } |
4237 | 4241 | ||
4238 | childAgentUpdate.ChildAgentDataUpdate(cAgentData); | 4242 | sp.ChildAgentDataUpdate(cAgentData); |
4239 | 4243 | ||
4240 | int ntimes = 20; | 4244 | int ntimes = 20; |
4241 | if (cAgentData.SenderWantsToWaitForRoot) | 4245 | if (cAgentData.SenderWantsToWaitForRoot) |
4242 | { | 4246 | { |
4243 | while (childAgentUpdate.IsChildAgent && ntimes-- > 0) | 4247 | while (sp.IsChildAgent && ntimes-- > 0) |
4244 | Thread.Sleep(1000); | 4248 | Thread.Sleep(1000); |
4245 | 4249 | ||
4246 | m_log.DebugFormat( | 4250 | m_log.DebugFormat( |
4247 | "[SCENE]: Found presence {0} {1} {2} in {3} after {4} waits", | 4251 | "[SCENE]: Found presence {0} {1} {2} in {3} after {4} waits", |
4248 | childAgentUpdate.Name, childAgentUpdate.UUID, childAgentUpdate.IsChildAgent ? "child" : "root", RegionInfo.RegionName, 20 - ntimes); | 4252 | sp.Name, sp.UUID, sp.IsChildAgent ? "child" : "root", Name, 20 - ntimes); |
4249 | 4253 | ||
4250 | if (childAgentUpdate.IsChildAgent) | 4254 | if (sp.IsChildAgent) |
4251 | return false; | 4255 | return false; |
4252 | } | 4256 | } |
4257 | |||
4253 | return true; | 4258 | return true; |
4254 | } | 4259 | } |
4260 | |||
4255 | return false; | 4261 | return false; |
4256 | } | 4262 | } |
4257 | 4263 | ||