On Wed, 2009-07-01 at 11:40 +0200, Bernhard 'Gustl' Bauer wrote: > Hi, > > I finally made some progress in my portscan problem. > > When I send out data, I get http_sent() calls. If all data is sent out I > call a tcp_close(). Unfortunately pcb->state is either ESTABLISHED or > CLOSE_WAIT and neither does free tcp_pcb.
That's odd. Is this the state before or after you've called tcp_close ()? If you've called tcp_close() it should be in FIN_WAIT1, FIN_WAIT2, CLOSING, or TIME_WAIT on its way to CLOSED. CLOSE_WAIT is entered if the other end closes the connection first, and then when you call tcp_close() it should move to LAST_ACK and then CLOSED. > One solution could be to use tcp_abort(). Another to set state to CLOSED > or SYN_SENT. How to do it right? tcp_close() is the right way to do it, but why the state is as you describe I'm not sure. Kieran _______________________________________________ lwip-users mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/lwip-users
