wqweto / VbAsyncSocket

Sockets with pure VB6 impl of TLS encryption
MIT License
164 stars 31 forks source link

[Improvement] Forcibly free the port #9

Closed dragokas closed 3 years ago

dragokas commented 3 years ago

Hi,

if my application crashed, how can I forcibly close the port? Any tips...

.Close_ didn't help me.

cAsyncSocket.cls: stack: ctxServer(0).Bind LocalPort, "localhost" ->

If ws_bind(m_hSocket, uAddr, LenB(uAddr)) = SOCKET_ERROR Then

LastDllError: Error: Usually only one use of the socket address (protocol / network address / port) is allowed

Very appreciate.

dragokas commented 3 years ago

I figured out that the problem is automatically get fixed if you run the program as Administrator (elevated).