in reply to Select on STDIN or ALARM?! For Win32 doesn't work!
IO::Select will not work for non-socket filehandles under Win32; that includes STD(IN|OUT).
A relevant quote from "Network Programming with Perl", by Lincoln D. Stein:
Win32 Issues
Another problem arises when using multiplexed applications on Microsoft Windows platforms. When I originally developed the scripts in these chapters, I tested them on Windows98 using ActiveState Perl, and everything seemed to work fine. Later, however, I discovered that the gab5.pl script (Figure 12.1) was consuming a large amount of CPU time, even when it was apparently doing nothing but waiting for keyboard input.
When I tracked down this problem, I learned that the Win32 port of Perl does not support select() on non-socket filehandles, including STDIN and STDOUT. So client-side scripts that multiplex across STDIN do not wait for the filehandle to be ready, but just loop.
|
|---|