fix: zero initMaxDatagramSize in brutal CC (wtf...)

This commit is contained in:
Toby 2022-02-03 20:54:30 -08:00
parent b593df44b7
commit a4a4130ba1
2 changed files with 6 additions and 4 deletions

View File

@ -6,6 +6,8 @@ import (
)
const (
initMaxDatagramSize = 1252
pktInfoSlotCount = 4
minSampleCount = 50
minAckRate = 0.75
@ -28,7 +30,8 @@ type pktInfo struct {
func NewBrutalSender(bps congestion.ByteCount) *BrutalSender {
bs := &BrutalSender{
bps: bps,
bps: bps,
maxDatagramSize: initMaxDatagramSize,
}
bs.pacer = newPacer(func() congestion.ByteCount {
return congestion.ByteCount(float64(bs.bps) / bs.getAckRate())

View File

@ -7,9 +7,8 @@ import (
)
const (
initMaxDatagramSize = 1252
maxBurstPackets = 10
minPacingDelay = time.Millisecond
maxBurstPackets = 10
minPacingDelay = time.Millisecond
)
// The pacer implements a token bucket pacing algorithm.