mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-10-05 22:29:49 +00:00
Duplicate FIN ACK race condition fix by Kelvin Lawson.
This commit is contained in:
parent
61cdbb30a6
commit
319a972e75
@ -938,7 +938,12 @@ tcp_receive(struct tcp_pcb *pcb)
|
|||||||
|
|
||||||
tcplen = TCP_TCPLEN(&inseg);
|
tcplen = TCP_TCPLEN(&inseg);
|
||||||
|
|
||||||
pcb->rcv_nxt += tcplen;
|
/* First received FIN will be ACKed +1, on any successive (duplicate)
|
||||||
|
* FINs we are already in CLOSE_WAIT and have already done +1.
|
||||||
|
*/
|
||||||
|
if (pcb->state != CLOSE_WAIT) {
|
||||||
|
pcb->rcv_nxt += tcplen;
|
||||||
|
}
|
||||||
|
|
||||||
/* Update the receiver's (our) window. */
|
/* Update the receiver's (our) window. */
|
||||||
if (pcb->rcv_wnd < tcplen) {
|
if (pcb->rcv_wnd < tcplen) {
|
||||||
|
Loading…
Reference in New Issue
Block a user