I am going for the simplest explanation. My Java TCP project has a server and three clients.
The server has a ClientThread. The clients each has a ServerThread and a Use
I think I have found the problem. I was using the same socket for a client program's ServerThread and UserThread. So while the ServerThread is trying to response to the server, most probably the message is going to another different thread in the server that is listening for message (thinking the message comes from UserThread) through the same socket.