W5500 can not recognize session has been disconnected in the server mode

I work with w5500. I have configured its socket number 2 as server and connect to it with a windows client. When client sends a connection request to w5500 server, the connection is well established. However, when the network is disconnected for every reason such as cable disconnecting,w5500 server can not crecognize it and the connection is kept established. But we know that the socket must be closed to let the client request another connection. Would you please tell a solution foyr this problem

W5500 already has timeout mechanism. timeout is occur by RTR/RCR register.
At the TCP packet retransmission timeout, W5500 transmits TCP packets(SYS, Data packets) and wait for ACK during the configured RTR and RCR time. If it is no ACK from the peer, a temporary timeout occurs and the TCP packet is retransmitted.

Therefore, when the network is disconnected for every reason such as cable disconnecting, W5500 will close the socket by timeout.

Thanks alot for your promt reply .i will try it .

when debug, everything is good and working. but If I shut down the computer then I cannot connect to the processor again. When you enter the ethernet settings from the control panel and turn the ethernet off and on, it works normally again. how to solve this error. can you help me. my mcu is working tcp server mode. ı am using tcp comunication.