Skip to content
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

tcp: fix racey simultaneous close not sending FIN. #398

Merged
merged 1 commit into from
Dec 28, 2020

Conversation

Dirbaio
Copy link
Member

@Dirbaio Dirbaio commented Dec 27, 2020

This fixes the issue identified in PR #279

In CLOSING state we may still have data or FIN to retransmit, or to transmit for the first time if we received a FIN before we had a chance to transmit it.

This fixes the issue by treating CLOSING similarly to FinWait1 and LastAck. This ensures data/FIN is always sent, and retransmitted in the case of timeout.

Copy link
Contributor

@whitequark whitequark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, though it's been a while since I worked on TCP and so for the most part I trust that you are making the correct change here.

@Dirbaio Dirbaio merged commit b175fae into master Dec 28, 2020
@Dirbaio Dirbaio deleted the simultaneous-close branch December 28, 2020 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants