fix NACKing of packets below lowest ACK range in new SentPacketHandler

This did not cause an error, since the packet didn't exist in the
packetHistory. With this fix, it is more consistent and it saves one
loop iteration.
This commit is contained in:
Marten Seemann
2016-08-03 13:13:32 +07:00
parent 0c873d69ec
commit 19f627af6f

View File

@@ -184,7 +184,7 @@ func (h *sentPacketHandler) ReceivedAck(ackFrame *frames.AckFrame, withPacketNum
var lostPackets congestion.PacketVector
// NACK packets below the LowestAcked
for i := h.LargestInOrderAcked; i < ackFrame.LowestAcked; i++ {
for i := h.LargestInOrderAcked + 1; i < ackFrame.LowestAcked; i++ {
p, err := h.nackPacket(i)
if err != nil {
return err