in reply to How to make sysread timeout
Typically you would use select (if you follow the link, you want the 4-arg version of select) or IO::Select to handle the timeout.
Unixish Shell Scripting languages
Other (post in comments)
Results (416 votes). Check out past polls.