Reinsert client.SceneAgent checks into LLUDPServer.HandleCompleteMovementIntoRegion() to fix race condition regression in commit 7dbc93c (Wed Sep 18 21:41:51 2013 +0100)

This check is necessary to close a race condition where the CompleteAgentMovement processing could proceed when the UseCircuitCode thread had added the client to the client manager but before the ScenePresence had registered to process the CompleteAgentMovement message.
This is most probably why the message appeared to get lost on a proportion of entity transfers.
A better long term solution may be to set the IClientAPI.SceneAgent property before the client is added to the manager.
This commit is contained in:
Justin Clark-Casey (justincc)
2013-09-25 18:45:56 +01:00
parent 732554be04
commit 32ddfc2740
2 changed files with 29 additions and 11 deletions

View File

@@ -2863,6 +2863,9 @@ namespace OpenSim.Region.Framework.Scenes
// We must set this here so that TriggerOnNewClient and TriggerOnClientLogin can determine whether the
// client is for a root or child agent.
// XXX: This may be better set for a new client before that client is added to the client manager.
// But need to know what happens in the case where a ScenePresence is already present (and if this
// actually occurs).
client.SceneAgent = sp;
// This is currently also being done earlier in NewUserConnection for real users to see if this