Attempt to address Mantis #1905, #1909

Prevent re-sequencing of resent packets. Thanks, ckrinke, for
catching that, it is what was happening.
0.6.0-stable
Melanie Thielker 2008-08-10 16:37:45 +00:00
parent 5acfc79c50
commit 9b7e66ceda
1 changed files with 16 additions and 11 deletions

View File

@ -240,6 +240,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
return; return;
} }
packet.Header.Sequence = 0;
lock (m_NeedAck) lock (m_NeedAck)
{ {
DropResend(id); DropResend(id);
@ -724,6 +726,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
packet.TickCount = System.Environment.TickCount; packet.TickCount = System.Environment.TickCount;
// Assign sequence number here to prevent out of order packets // Assign sequence number here to prevent out of order packets
if(packet.Header.Sequence == 0)
{
packet.Header.Sequence = NextPacketSequenceNumber(); packet.Header.Sequence = NextPacketSequenceNumber();
lock (m_NeedAck) lock (m_NeedAck)
@ -736,6 +740,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
item.Identifier); item.Identifier);
} }
} }
}
// Actually make the byte array and send it // Actually make the byte array and send it
try try