Then say a four way select() & sysread() until sysread returns 0. Same can be said for syswrite() but without the select() and zero byte check.
I'm aware that print and read are buffered, but i'm aware of little more than that ;-)
To conclude, i reckon i will implement what was first decided on Sunday, and that is using sysread() to fill up the target scalar, it has been interesting however to have seen the other options, TMTOWTDI indeed.
I could be wrong. I can't find anything in the documentation saying you can't use sys* on a filehandle opened with open. Maybe it works on some systems but not on others (like sockets requiring the use of the system functions). Maybe it's a convention I adopted to be on the safe side.
However, you definitely can't intermiggle buffered and system file operations. For example, I can across a piece of code that used select, eof and sysread. It didn't work because sysread always returned 0. eof would move the data from the pipe into the buffer. After changing sysread to read, everything worked fine.