mirror of
https://github.com/opensim/opensim.git
synced 2026-08-06 09:16:28 +08:00
Go easy on enforcing session ids in position updates
This commit is contained in:
@@ -4267,24 +4267,25 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
ScenePresence childAgentUpdate = GetScenePresence(cAgentData.AgentID);
|
||||
if (childAgentUpdate != null)
|
||||
{
|
||||
if (childAgentUpdate.ControllingClient.SessionId == cAgentData.SessionID)
|
||||
if (childAgentUpdate.ControllingClient.SessionId != cAgentData.SessionID)
|
||||
// Only warn for now
|
||||
m_log.WarnFormat("[SCENE]: Attempt at updating position of agent {0} with invalid session id {1}. Neighbor running older version?",
|
||||
childAgentUpdate.UUID, cAgentData.SessionID);
|
||||
|
||||
// I can't imagine *yet* why we would get an update if the agent is a root agent..
|
||||
// however to avoid a race condition crossing borders..
|
||||
if (childAgentUpdate.IsChildAgent)
|
||||
{
|
||||
// I can't imagine *yet* why we would get an update if the agent is a root agent..
|
||||
// however to avoid a race condition crossing borders..
|
||||
if (childAgentUpdate.IsChildAgent)
|
||||
{
|
||||
uint rRegionX = (uint)(cAgentData.RegionHandle >> 40);
|
||||
uint rRegionY = (((uint)(cAgentData.RegionHandle)) >> 8);
|
||||
uint tRegionX = RegionInfo.RegionLocX;
|
||||
uint tRegionY = RegionInfo.RegionLocY;
|
||||
//Send Data to ScenePresence
|
||||
childAgentUpdate.ChildAgentDataUpdate(cAgentData, tRegionX, tRegionY, rRegionX, rRegionY);
|
||||
// Not Implemented:
|
||||
//TODO: Do we need to pass the message on to one of our neighbors?
|
||||
}
|
||||
uint rRegionX = (uint)(cAgentData.RegionHandle >> 40);
|
||||
uint rRegionY = (((uint)(cAgentData.RegionHandle)) >> 8);
|
||||
uint tRegionX = RegionInfo.RegionLocX;
|
||||
uint tRegionY = RegionInfo.RegionLocY;
|
||||
//Send Data to ScenePresence
|
||||
childAgentUpdate.ChildAgentDataUpdate(cAgentData, tRegionX, tRegionY, rRegionX, rRegionY);
|
||||
// Not Implemented:
|
||||
//TODO: Do we need to pass the message on to one of our neighbors?
|
||||
}
|
||||
else
|
||||
m_log.WarnFormat("[SCENE]: Attempt at updating position of agent {0} with invalid session id {1}", childAgentUpdate.UUID, cAgentData.SessionID);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user