Partial fix for bug #15926, flushing TCP output in do_close().

This commit is contained in:
christiaans 2006-08-07 10:00:44 +00:00
parent d8922d0410
commit a82e02ef15

View File

@ -761,7 +761,10 @@ do_close(struct api_msg_msg *msg)
#if LWIP_TCP
case NETCONN_TCP:
if (msg->conn->pcb.tcp->state == LISTEN) {
err = tcp_close(msg->conn->pcb.tcp);
err = tcp_close(msg->conn->pcb.tcp);
}
else if (msg->conn->pcb.tcp->state == CLOSE_WAIT) {
err = tcp_output(msg->conn->pcb.tcp);
}
msg->conn->err = err;
#endif