mirror of
https://github.com/refraction-networking/uquic.git
synced 2025-04-04 12:47:36 +03:00
never keep track of more than 500 ACK ranges
This is achieved by deleting the oldest ACK ranges when receiving a packet that creates a new ACK range such that this limit is exceeded.
This commit is contained in:
parent
320d4a868e
commit
475ba63164
4 changed files with 30 additions and 43 deletions
|
@ -59,19 +59,6 @@ var _ = Describe("Received Packet Tracker", func() {
|
|||
Expect(tracker.largestObserved).To(Equal(protocol.PacketNumber(5)))
|
||||
Expect(tracker.largestObservedReceivedTime).To(Equal(timestamp))
|
||||
})
|
||||
|
||||
It("passes on errors from receivedPacketHistory", func() {
|
||||
var err error
|
||||
for i := protocol.PacketNumber(0); i < 5*protocol.MaxTrackedReceivedAckRanges; i++ {
|
||||
err = tracker.ReceivedPacket(2*i+1, time.Time{}, true)
|
||||
// this will eventually return an error
|
||||
// details about when exactly the receivedPacketHistory errors are tested there
|
||||
if err != nil {
|
||||
break
|
||||
}
|
||||
}
|
||||
Expect(err).To(MatchError(errTooManyOutstandingReceivedAckRanges))
|
||||
})
|
||||
})
|
||||
|
||||
Context("ACKs", func() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue