Subject: | Buffered reads with select |
Date: | Wed, 17 Aug 2011 16:56:26 +0200 |
To: | bug-Net-UCP [...] rt.cpan.org |
From: | Péli Gergely <pgergo [...] deverto.com> |
Dear maintainer,
We use this package, and experienced occassional hangups in a "select" system call, even if the data actually arrived to the socket. Seems like the code uses the Perl "read" function to read from sockets, which is buffered read, and using it with "select" is a bad idea, since if may buffer subsequent data, which won't be reported by "select". Replacing the "read" calls with "sysread"-s solved the problems for us.
Best regards
Gergely Peli