forked from quic-go/quic-go
queue RTO retransmissions before checking for congestion window size
This commit is contained in:
@@ -421,16 +421,16 @@ func (s *Session) maybeSendPacket() error {
|
||||
return s.sendPacket()
|
||||
}
|
||||
|
||||
if !s.sentPacketHandler.CongestionAllowsSending() {
|
||||
return nil
|
||||
}
|
||||
|
||||
// always send out retransmissions immediately. No need to check the size of the packet
|
||||
// in the edge cases where a belated ACK was received for a packet that was already queued for retransmission, we might send out a small packet. However, this shouldn't happen very often
|
||||
if s.sentPacketHandler.ProbablyHasPacketForRetransmission() {
|
||||
return s.sendPacket()
|
||||
}
|
||||
|
||||
if !s.sentPacketHandler.CongestionAllowsSending() {
|
||||
return nil
|
||||
}
|
||||
|
||||
var maxPacketSize protocol.ByteCount // the maximum size of a packet we could send out at this moment
|
||||
|
||||
// we only estimate the size of the StopWaitingFrame here
|
||||
|
||||
Reference in New Issue
Block a user