Use padding for probing (#434)

* WIP commit

* WIP commit

* WIP commit

* WIP commit

* WIP commit

* WIP commit

* WIP commit

* WIP commit

* Clean up

* Remove debug

* Remove unneeded change

* fix test

* Remove incorrect comment

* Reset probe after estimate trends down
This commit is contained in:
Raja Subramanian
2022-02-17 11:03:23 +05:30
committed by GitHub
parent c534099e3a
commit 0bbed7f0bd
11 changed files with 690 additions and 207 deletions
+1 -1
View File
@@ -34,7 +34,7 @@ func (b *Bucket) AddPacket(pkt []byte) ([]byte, error) {
}
diff := sn - b.headSN
if diff == 0 || diff > (1<<15) {
// duplicate of lsat packet or out-of-order
// duplicate of last packet or out-of-order
return b.set(sn, pkt)
}
b.headSN = sn