Tracy
Tracy

Reputation: 1998

questions about tcp half-close

please see the following pic:

enter image description here

the client initiate a half-close request and get acknowledged,if i dont misunderstand what half-close means,the client should not be able to send any data afterwards, then how can it send back an ACK later.

Upvotes: 1

Views: 1362

Answers (1)

Nikolai Fetissov
Nikolai Fetissov

Reputation: 84189

It's not the client data that is being sent, it the acknowledgement for the server data received after client does shutdown( fd, SHUT_WR ), which means client will not send anymore, but can still receive. The ACK itself is part of the transport protocol, not the application.

Upvotes: 7

Related Questions