diff options
author | Melanie | 2012-06-06 13:07:05 +0100 |
---|---|---|
committer | Melanie | 2012-06-06 13:07:05 +0100 |
commit | e733fb32cf76672cfddc25b3c9c02c50c025e2db (patch) | |
tree | 1535c9e7d70cdb5f2e0779db8fc85fb98ede7ca5 /OpenSim/Region/ClientStack/Linden | |
parent | Merge branch 'master' into careminster (diff) | |
parent | minor: Change log messages on Warp3DImageModule to show they are from this mo... (diff) | |
download | opensim-SC-e733fb32cf76672cfddc25b3c9c02c50c025e2db.zip opensim-SC-e733fb32cf76672cfddc25b3c9c02c50c025e2db.tar.gz opensim-SC-e733fb32cf76672cfddc25b3c9c02c50c025e2db.tar.bz2 opensim-SC-e733fb32cf76672cfddc25b3c9c02c50c025e2db.tar.xz |
Merge branch 'master' into careminster
Conflicts:
OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs
OpenSim/Region/Framework/Scenes/Scene.cs
OpenSim/Region/Framework/Scenes/SimStatsReporter.cs
Diffstat (limited to 'OpenSim/Region/ClientStack/Linden')
-rw-r--r-- | OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs index dda4444..d310d65 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs | |||
@@ -155,7 +155,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
155 | 155 | ||
156 | private int m_defaultRTO = 0; | 156 | private int m_defaultRTO = 0; |
157 | private int m_maxRTO = 0; | 157 | private int m_maxRTO = 0; |
158 | 158 | private int m_ackTimeout = 0; | |
159 | private int m_pausedAckTimeout = 0; | ||
159 | private bool m_disableFacelights = false; | 160 | private bool m_disableFacelights = false; |
160 | 161 | ||
161 | public Socket Server { get { return null; } } | 162 | public Socket Server { get { return null; } } |
@@ -198,11 +199,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
198 | m_defaultRTO = config.GetInt("DefaultRTO", 0); | 199 | m_defaultRTO = config.GetInt("DefaultRTO", 0); |
199 | m_maxRTO = config.GetInt("MaxRTO", 0); | 200 | m_maxRTO = config.GetInt("MaxRTO", 0); |
200 | m_disableFacelights = config.GetBoolean("DisableFacelights", false); | 201 | m_disableFacelights = config.GetBoolean("DisableFacelights", false); |
202 | m_ackTimeout = 1000 * config.GetInt("AckTimeout", 60); | ||
203 | m_pausedAckTimeout = 1000 * config.GetInt("PausedAckTimeout", 300); | ||
201 | } | 204 | } |
202 | else | 205 | else |
203 | { | 206 | { |
204 | PrimUpdatesPerCallback = 100; | 207 | PrimUpdatesPerCallback = 100; |
205 | TextureSendLimit = 20; | 208 | TextureSendLimit = 20; |
209 | m_ackTimeout = 1000 * 60; // 1 minute | ||
210 | m_pausedAckTimeout = 1000 * 300; // 5 minutes | ||
206 | } | 211 | } |
207 | 212 | ||
208 | #region BinaryStats | 213 | #region BinaryStats |
@@ -491,8 +496,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
491 | return; | 496 | return; |
492 | 497 | ||
493 | // Disconnect an agent if no packets are received for some time | 498 | // Disconnect an agent if no packets are received for some time |
494 | //FIXME: Make 60 an .ini setting | 499 | int timeoutTicks = m_ackTimeout; |
495 | if ((Environment.TickCount & Int32.MaxValue) - udpClient.TickLastPacketReceived > 1000 * 60) | 500 | |
501 | // Allow more slack if the client is "paused" eg file upload dialogue is open | ||
502 | // Some sort of limit is needed in case the client crashes, loses its network connection | ||
503 | // or some other disaster prevents it from sendung the AgentResume | ||
504 | if (udpClient.IsPaused) | ||
505 | timeoutTicks = m_pausedAckTimeout; | ||
506 | |||
507 | if ((Environment.TickCount & Int32.MaxValue) - udpClient.TickLastPacketReceived > timeoutTicks) | ||
496 | { | 508 | { |
497 | m_log.Warn("[LLUDPSERVER]: Ack timeout, disconnecting " + udpClient.AgentID); | 509 | m_log.Warn("[LLUDPSERVER]: Ack timeout, disconnecting " + udpClient.AgentID); |
498 | StatsManager.SimExtraStats.AddAbnormalClientThreadTermination(); | 510 | StatsManager.SimExtraStats.AddAbnormalClientThreadTermination(); |