On 11-06-07 01:47 AM, Breno G. de Oliveira via RT wrote:
Show quoted text> perl -Mstrict -Mwarnings -MFcntl -e 'my @flags = ( O_APPEND, O_ASYNC,
> O_CREAT, O_TRUNC, O_NONBLOCK ); print qq[@flags]'
$ perl -Mstrict -Mwarnings -MFcntl -e 'my @flags = ( O_APPEND,
O_ASYNC,O_CREAT, O_TRUNC, O_NONBLOCK ); print qq[@flags]'
Your vendor has not defined Fcntl macro O_ASYNC, used at -e line 1.
Show quoted text> perl -Mstrict -Mwarnings -MFcntl -e 'sysopen my $fh, q[somefile.tmp],
> O_CREAT|O_APPEND or die $!; my $flags = fcntl($fh, F_GETFL, 0); print 42
> . $/ if $flags & O_APPEND;'
$ perl -Mstrict -Mwarnings -MFcntl -e 'sysopen my $fh, q[somefile.tmp],
O_CREAT|O_APPEND or die $!; my $flags = fcntl($fh, F_GETFL, 0); print 42
. $/ if $flags & O_APPEND;'
42
Show quoted text> Finally, knowing your Filesystem would also be nice. I'm guessing ZFS,
> but it doesn't hurt being sure :)
I believe the filesystem is UFS.
Show quoted text> Also, your perl version (perl -v) and Fcntl version (perl -MFcntl -e
> 'print $Fcntl::VERSION') would be nice to know and might help solving this.
$ perl -v ; perl -MFcntl -e 'print $Fcntl::VERSION, "\n"'
This is perl 5, version 12, subversion 3 (v5.12.3) built for sun4-solaris
...
$ perl -MFcntl -e 'print $Fcntl::VERSION, "\n"'
1.06
Show quoted text> Finally, checking if all the mentioned flags ( O_APPEND, O_ASYNC,
> O_CREAT, O_TRUNC, O_NONBLOCK ) are listed in "man 2 open" would also be
> of great help.
Only O_ASYNC is not mentioned.
-Mike