I am using Astreams for a socket server.
I am creating a array for each new connection e.g
Sub Server_NewConnection (Successful As Boolean, NewSocket As Socket)
If Successful Then
Log("Connected")
Sockets(k) = NewSocket
k=k+1
end if
Server.Listen
End Sub
when a client disconnects from the server the AStreams_Terminated is fired but is there anyway to tell which sockets(k) is being disconnected ?
does the AStreams_Terminated not fire with additional variables to say which socket is being dropped.
I am creating a array for each new connection e.g
Sub Server_NewConnection (Successful As Boolean, NewSocket As Socket)
If Successful Then
Log("Connected")
Sockets(k) = NewSocket
k=k+1
end if
Server.Listen
End Sub
when a client disconnects from the server the AStreams_Terminated is fired but is there anyway to tell which sockets(k) is being disconnected ?
does the AStreams_Terminated not fire with additional variables to say which socket is being dropped.