diff options
author | Melanie Thielker | 2008-09-28 18:07:06 +0000 |
---|---|---|
committer | Melanie Thielker | 2008-09-28 18:07:06 +0000 |
commit | 95c3e0883c35dcb9b4d5f7dc77608f16bea3b992 (patch) | |
tree | 6ec8e461e458575905848aed83d79b25874b6b60 | |
parent | Mantis#2289. Thank you kindly, SMeans for a patch that: (diff) | |
download | opensim-SC_OLD-95c3e0883c35dcb9b4d5f7dc77608f16bea3b992.zip opensim-SC_OLD-95c3e0883c35dcb9b4d5f7dc77608f16bea3b992.tar.gz opensim-SC_OLD-95c3e0883c35dcb9b4d5f7dc77608f16bea3b992.tar.bz2 opensim-SC_OLD-95c3e0883c35dcb9b4d5f7dc77608f16bea3b992.tar.xz |
Mantis #2288
Correct a typo in namespace declaration
Also adds a new flag to the PacketManager to force retention of packets
marked reliable (default off)
Diffstat (limited to '')
-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 | } |