mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-27 17:52:43 +00:00
tcp: Undo the increase in sequence number by 1 due to the FIN flag in case of a transient error.
If an error occurs while processing a TCP segment with some data and the FIN flag, the back out of the sequence number advance does not take into account the increase by 1 due to the FIN flag. Reviewed By: jch, gnn, #transport, tuexen Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D2970
This commit is contained in:
parent
a7399ea2dd
commit
66605ff791
@ -1681,8 +1681,13 @@ timer:
|
||||
tp->sackhint.sack_bytes_rexmit -= len;
|
||||
KASSERT(tp->sackhint.sack_bytes_rexmit >= 0,
|
||||
("sackhint bytes rtx >= 0"));
|
||||
} else
|
||||
KASSERT((flags & TH_FIN) == 0,
|
||||
("error while FIN with SACK rxmit"));
|
||||
} else {
|
||||
tp->snd_nxt -= len;
|
||||
if (flags & TH_FIN)
|
||||
tp->snd_nxt--;
|
||||
}
|
||||
}
|
||||
SOCKBUF_UNLOCK_ASSERT(&so->so_snd); /* Check gotos. */
|
||||
switch (error) {
|
||||
|
Loading…
Reference in New Issue
Block a user