logoalt Hacker News

Joker_vDyesterday at 5:57 PM1 replyview on HN

> Send off the data and close the socket. If there's data still pending to be read, this will cause a RST, I think.

Um, yes? That's how TCP has been universally implemented for more than 30 years. See [0], 2.17 for discussion.

[0] https://www.rfc-editor.org/rfc/rfc2525#page-50


Replies

eggnetyesterday at 7:02 PM

That’s for rx, not tx. When you close a socket with data in the send buffer, that does not trigger a RST. If you just close the socket normally.

show 1 reply