Hi I have server code:
And client socket is connected to server and loop to send message to server, at end of each loop to close socket:
The problem is server can only receive message at first loop, then it cannot get any message after other ones.
At the server side, if we don't set running as false when capture socket close ( which mean keep first
thread alive), then work fine, at this case, server will increase number of thread if there are a lot of client to connect? how to solve this issue?
Thanks,
Kinson