This is likely the reason you lose data you are expecting at the server.
You probably need to change "while(<$session>)" to "while (my $msgout=<>)" in your "sub sock_io".
Also, I suggest you do a blocking accept in your server, to avoid the busy loop (Research on this left as an exercise).
"An undefined problem has an infinite number of solutions." - Robert A. Humphrey "If you're not part of the solution, you're part of the precipitate." - Henry J. Tillman
In reply to Re: problem with sockets and CRLF and threads
by NetWallah
in thread problem with sockets and CRLF and threads
by spx2
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |