calculate the packet number length in the sent packet handler

This commit is contained in:
Marten Seemann
2018-03-07 15:56:18 +07:00
parent c37433abce
commit abf57a5551
8 changed files with 34 additions and 37 deletions

View File

@@ -354,8 +354,8 @@ func (h *sentPacketHandler) DequeuePacketForRetransmission() *Packet {
return packet
}
func (h *sentPacketHandler) GetLeastUnacked() protocol.PacketNumber {
return h.lowestUnacked()
func (h *sentPacketHandler) GetPacketNumberLen(p protocol.PacketNumber) protocol.PacketNumberLen {
return protocol.GetPacketNumberLengthForHeader(p, h.lowestUnacked())
}
func (h *sentPacketHandler) GetStopWaitingFrame(force bool) *wire.StopWaitingFrame {