Subj : exec/load/binkp.js To : Git commit to main/sbbs/master From : Deuce Date : Wed Dec 02 2020 12:49 pm https://gitlab.synchro.net/main/sbbs/-/commit/a0b4a7cf8e4e1b79e75805ed Modified Files: exec/load/binkp.js Log Message: 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. .