in reply to Linux device filehandle roadblock
Something like (totally pseudo-code):
The error "error that says "item O_RDONLY isn't numeric at line 3" may be caused by not having "use Fnctl;" at the top.sysopen FH, /dev/fd0, O_RDWR|O_CREAT,0666 or die "Cannot open : $!"; while(1){ seek FH, 0, SEEK_SET or die "Cannot rewind $file: $!"; my $data = <FH>; #truncate FH, 0 print "$data\n"; }
|
|---|