Explorar o código

Actually put IsChildAgent = true inside the lock, otherwise there is still a small window for race conditions on duplicate CompleteMovement calls

Justin Clark-Casey (justincc) %!s(int64=10) %!d(string=hai) anos
pai
achega
3bc669ffc7
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      OpenSim/Region/Framework/Scenes/ScenePresence.cs

+ 3 - 1
OpenSim/Region/Framework/Scenes/ScenePresence.cs

@@ -933,10 +933,12 @@ namespace OpenSim.Region.Framework.Scenes
             //m_log.DebugFormat("[SCENE]: known regions in {0}: {1}", Scene.RegionInfo.RegionName, KnownChildRegionHandles.Count);
 
             lock (m_completeMovementLock)
+            {
                 if (!IsChildAgent)
                     return false;
 
-            IsChildAgent = false;
+                IsChildAgent = false;
+            }
 
             // Must reset this here so that a teleport to a region next to an existing region does not keep the flag
             // set and prevent the close of the connection on a subsequent re-teleport.