mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 17:55:48 +08:00
Stop error messages being misleadingly generated when on client connection activity timeout, a root connection triggers a CloseAgent to a neighbour region which has already closed the agent due to inactivity.
Also separates out log messages to distinguish between close not finding an agent and wrong auth token, and downgrades former to debug and latter to warn
This commit is contained in:
@@ -4416,10 +4416,27 @@ namespace OpenSim.Region.Framework.Scenes
|
||||
|
||||
// Check that the auth_token is valid
|
||||
AgentCircuitData acd = AuthenticateHandler.GetAgentCircuitData(agentID);
|
||||
if (acd != null && acd.SessionID.ToString() == auth_token)
|
||||
|
||||
if (acd == null)
|
||||
{
|
||||
m_log.DebugFormat(
|
||||
"[SCENE]: Request to close agent {0} but no such agent in scene {1}. May have been closed previously.",
|
||||
agentID, Name);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
if (acd.SessionID.ToString() == auth_token)
|
||||
{
|
||||
return IncomingCloseAgent(agentID, force);
|
||||
}
|
||||
else
|
||||
m_log.ErrorFormat("[SCENE]: Request to close agent {0} with invalid authorization token {1}", agentID, auth_token);
|
||||
{
|
||||
m_log.WarnFormat(
|
||||
"[SCENE]: Request to close agent {0} with invalid authorization token {1} in {2}",
|
||||
agentID, auth_token, Name);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user