Home > Back-end >  Close the socket, turn the difference
Close the socket, turn the difference

Time:09-16

Younger brother today doing the experiment, there is a phenomenon is not clear to help you a great god, and the initial state is to serve the client and the client socket connection is normal, the client every two seconds to send data to the server, and then the server disconnected by two different ways, one is close, the other one is shutdown (SHUT_RD)), using the close, the client sends data will appear "connection reset by peer", and then USES the shutdown will not appear, caught looked really successful, also shutdown (SHUT_WR) and close causes hair of fin do not have what differentiation? Why are there different phenomenon? Beginner network, help you a great god
  • Related