-
- Downloads
Perform super-graceful shutdown of the socket on success.
This should guard against a RST being sent on success. It's possible that the remote has sent data (ie: M_EOB) we would recv() after we commit to ending the session. If the script terminates while there is data to be read, this would result in sending a RST. To prevent this, we call shutdown(sock, SHUT_WR) via setting is_writeable to false (because that's how we roll), then recv() all data until the remote closes the session, or the timeout passes.
Loading
Please register or sign in to comment