The tcp_abort function closes the TCP connection immediately by sending a TCP frame with the RESET flag set to the remote machine. The argument socket specifies the handle of the socket whose connection is to be closed. TCPnet calls the listener callback function only, when a remote peer has aborted the connection. If the socket aborting is initiated locally by calling tcp_abort, the callback function is not called. The tcp_abort function is in the RL-TCPnet library. The prototype is defined in rtl.h. note - After calling tcp_abort you cannot use the socket to send or receive any data.
- After calling tcp_abort the socket still remains allocated until you release it.
|