How the server will know the client(windows) has shutdown the socket ??
For UDP server, it should be handled by an application protocol.
For TCP server, the connection is closed automatically, in case of connection graceful shutdown or reset.
If client was physically unplugged and no shutdown was detected by the server, the TCP keep-alive mechanism is used => the connection will be closed in some timeout.
Any manipulations (recv(), send() etc.) with a TCP socket that has closed connection will cause error.
Retrieving data ...