Another fix for bug #20021: by not returning an error if tcp_output fails in tcp_close, the code in do_close_internal gets simpler (tcp_output is called again later from tcp timers).

This commit is contained in:
goldsimon
2007-07-25 19:24:27 +00:00
parent f9c30017b0
commit f4036e8352
3 changed files with 36 additions and 47 deletions

View File

@@ -190,7 +190,11 @@ tcp_close(struct tcp_pcb *pcb)
}
if (pcb != NULL && err == ERR_OK) {
err = tcp_output(pcb);
/* @todo: to ensure all has been sent when tcp_close returns, we have to
make sure tcp_output doesn't fail.
For now (and as long as we don't need this (no LINGER)), it's enough
to let the TCP timers deal with this. */
tcp_output(pcb);
}
return err;
}