mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-04-17 11:42:56 +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);
|
||||
|
||||
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. */
|
||||
if (pcb->rcv_wnd < tcplen) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user