mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-11-06 20:29:04 +00:00
Fixed trying to send RST for unconnected (but bound) pcb
This commit is contained in:
parent
4ec3d29168
commit
6c0d78caaa
@ -464,9 +464,11 @@ tcp_abandon(struct tcp_pcb *pcb, int reset)
|
||||
errf = pcb->errf;
|
||||
#endif /* LWIP_CALLBACK_API */
|
||||
errf_arg = pcb->callback_arg;
|
||||
if ((pcb->state == CLOSED) && (pcb->local_port != 0)) {
|
||||
/* bound, not yet opened */
|
||||
TCP_RMV(&tcp_bound_pcbs, pcb);
|
||||
if (pcb->state == CLOSED) {
|
||||
if (pcb->local_port != 0) {
|
||||
/* bound, not yet opened */
|
||||
TCP_RMV(&tcp_bound_pcbs, pcb);
|
||||
}
|
||||
} else {
|
||||
send_rst = reset;
|
||||
local_port = pcb->local_port;
|
||||
|
Loading…
Reference in New Issue
Block a user