When a connection is terminated in winsock - is _close ALWAYS fired?
Anyone know? For errors, or connections closed by the server or the client, timeouts, etc.. does the _close always fire?
Re: When a connection is terminated in winsock - is _close ALWAYS fired?
It should, if not, you can use the 'Winsock.State <> sckClosed' function to check it on error, or whatever else you need it for.
Re: When a connection is terminated in winsock - is _close ALWAYS fired?
I don'T think you will get an _close in any case.
Because of that reason you should always check the state of a connection before using it like:
Code:
If Winsock.State <> sckClosed Then
Winsock.Close
End If