mirror of
https://github.com/nonoo/kappanhang.git
synced 2025-12-06 08:02:00 +01:00
Revert "Remove out of order check as it is already done by the RX seqbuf"
This reverts commit 55b220d14d.
This commit is contained in:
parent
f870a0f7c4
commit
ffddab2822
|
|
@ -65,6 +65,12 @@ func (s *serialStream) sendOpenClose(close bool) error {
|
||||||
func (s *serialStream) handleRxSeqBufEntry(e seqBufEntry) {
|
func (s *serialStream) handleRxSeqBufEntry(e seqBufEntry) {
|
||||||
gotSeq := uint16(e.seq)
|
gotSeq := uint16(e.seq)
|
||||||
if s.receivedSerialData {
|
if s.receivedSerialData {
|
||||||
|
// Out of order packets can happen if we receive a retransmitted packet, but too late.
|
||||||
|
if s.rxSeqBuf.leftOrRightCloserToSeq(e.seq, seqNum(s.lastReceivedSeq)) != left {
|
||||||
|
log.Debug("got out of order pkt seq #", e.seq)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
expectedSeq := s.lastReceivedSeq + 1
|
expectedSeq := s.lastReceivedSeq + 1
|
||||||
if expectedSeq != gotSeq {
|
if expectedSeq != gotSeq {
|
||||||
var missingPkts int
|
var missingPkts int
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue