TCP: attempt to flush the write buffers before closing
When a socket is closed, it should make sure that any pending write data is sent before the FIN is sent. It already would wait for all sent data to be acked, however it would discard any pending write data that had not been sent at least once. This change adds a check for pending write data in addition to unacked data. However, to be able to actually send any new data, the send callback must be left. The callback should be freed later when the socket is actually destroyed.
parent
cdd187a7
Please register or sign in to comment