Skip to content

Delay socket close so to (re)send final ACK if needed. #29

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

michau-krakow
Copy link

The https://www.rfc-editor.org/rfc/rfc1350, section 6, Normal Termination recommends not to close client connection immediately, but rather wait for a while, as the final ACK may be lost in the network.
In such case the client would re-transmit final DATA packet expecting server to send a final ACK again.

This is also fixing #5 when socket is closed too fast, effectively causing final ACK to be lost.

Socket will be closed on the next retransmission timer expiry
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant