open mode

If you expect to use both read and write operations on the device, you'll have to open it for update (see perlfunc/"open" for details). You may wish to open it without running the risk of blocking by using sysopen() and O_RDWR|O_NDELAY|O_NOCTTY from the Fcntl module (part of the standard perl distribution). See perlfunc/"sysopen" for more on this approach.


Back to perlfaq8