I have a problem, my HTTP server freezes after a few days of operation. I found that this is due to the fact that the state of the socket is not completely closed (FIN_WAIT (= 0x18)).
I work with W5500 on interrupts, so I can not once again interrogate and see the state of FIN_WAIT, to send comand CLOSED
maybe I skip interruption of disconnection on this so it all happens.
- I can not understand why the socket does not go into the CLOSED state?
- what external event or internal could trigger such a change?
There are also some questions about the operation of the TCP server
- In the LISTEN state, should a timeout and socket re-open occur?