diff options
Diffstat (limited to 'OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs')
-rw-r--r-- | OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs b/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs index 149fa9a..ea397c7 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLPacketHandler.cs | |||
@@ -191,7 +191,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
191 | private object m_SequenceLock = new object(); | 191 | private object m_SequenceLock = new object(); |
192 | private const int MAX_SEQUENCE = 0xFFFFFF; | 192 | private const int MAX_SEQUENCE = 0xFFFFFF; |
193 | 193 | ||
194 | // Packet dropping | ||
195 | // | ||
194 | List<PacketType> m_ImportantPackets = new List<PacketType>(); | 196 | List<PacketType> m_ImportantPackets = new List<PacketType>(); |
197 | private bool m_ReliableIsImportant = false; | ||
198 | |||
199 | public bool ReliableIsImportant | ||
200 | { | ||
201 | get { return m_ReliableIsImportant; } | ||
202 | set { m_ReliableIsImportant = value; } | ||
203 | } | ||
195 | 204 | ||
196 | LLPacketServer m_PacketServer; | 205 | LLPacketServer m_PacketServer; |
197 | private byte[] m_ZeroOutBuffer = new byte[4096]; | 206 | private byte[] m_ZeroOutBuffer = new byte[4096]; |
@@ -359,12 +368,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
359 | // | 368 | // |
360 | if ((now - data.TickCount) > m_DiscardTimeout) | 369 | if ((now - data.TickCount) > m_DiscardTimeout) |
361 | { | 370 | { |
362 | if (!m_ImportantPackets.Contains(packet.Type)) | 371 | if (!m_ReliableIsImportant || !packet.Header.Reliable) |
363 | m_NeedAck.Remove(packet.Header.Sequence); | 372 | { |
373 | if (!m_ImportantPackets.Contains(packet.Type)) | ||
374 | m_NeedAck.Remove(packet.Header.Sequence); | ||
364 | 375 | ||
365 | TriggerOnPacketDrop(packet, data.Identifier); | 376 | TriggerOnPacketDrop(packet, data.Identifier); |
366 | 377 | ||
367 | continue; | 378 | continue; |
379 | } | ||
368 | } | 380 | } |
369 | } | 381 | } |
370 | } | 382 | } |