diff options
author | Justin Clark-Casey (justincc) | 2013-08-15 14:07:57 +0100 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2013-08-15 14:07:57 +0100 |
commit | 3f8d79024bc760e4f0c5cbca2126ab725c847078 (patch) | |
tree | c9e8bdb7464da618e446298f8556bdebf72bb9ee /OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |
parent | Do not use the SP.DoNotCloseAfterTeleport flag for child agent connections. (diff) | |
download | opensim-SC_OLD-3f8d79024bc760e4f0c5cbca2126ab725c847078.zip opensim-SC_OLD-3f8d79024bc760e4f0c5cbca2126ab725c847078.tar.gz opensim-SC_OLD-3f8d79024bc760e4f0c5cbca2126ab725c847078.tar.bz2 opensim-SC_OLD-3f8d79024bc760e4f0c5cbca2126ab725c847078.tar.xz |
Rely on the Scene.IncomingCloseAgent() check as to whether the connection should be kept open after teleport-end rather than doing this in the ET Module
This is safer since the close check in IncomingCloseAgent() is done under lock conditions, which prevents a race between ETM and Scene.AddClient()
Diffstat (limited to 'OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs')
-rw-r--r-- | OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | 20 |
1 files changed, 6 insertions, 14 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index 93a089d..5f85eb0 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |||
@@ -1085,20 +1085,12 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1085 | // IN THE AVIE BEING PLACED IN INFINITY FOR A COUPLE OF SECONDS. | 1085 | // IN THE AVIE BEING PLACED IN INFINITY FOR A COUPLE OF SECONDS. |
1086 | Thread.Sleep(15000); | 1086 | Thread.Sleep(15000); |
1087 | 1087 | ||
1088 | if (!sp.DoNotCloseAfterTeleport) | 1088 | // OK, it got this agent. Let's close everything |
1089 | { | 1089 | // If we shouldn't close the agent due to some other region renewing the connection |
1090 | // OK, it got this agent. Let's close everything | 1090 | // then this will be handled in IncomingCloseAgent under lock conditions |
1091 | m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Closing agent {0} in {1}", sp.Name, Scene.Name); | 1091 | m_log.DebugFormat( |
1092 | sp.Scene.IncomingCloseAgent(sp.UUID, false); | 1092 | "[ENTITY TRANSFER MODULE]: Closing agent {0} in {1} after teleport", sp.Name, Scene.Name); |
1093 | } | 1093 | sp.Scene.IncomingCloseAgent(sp.UUID, false); |
1094 | else | ||
1095 | { | ||
1096 | m_log.DebugFormat( | ||
1097 | "[ENTITY TRANSFER MODULE]: Connection for {0} in {1} has been re-established after teleport. Not closing.", | ||
1098 | sp.Name, Scene.Name); | ||
1099 | |||
1100 | sp.DoNotCloseAfterTeleport = false; | ||
1101 | } | ||
1102 | } | 1094 | } |
1103 | else | 1095 | else |
1104 | { | 1096 | { |