From: Gurusamy Sarathy Date: Wed, 7 Jul 1999 10:27:55 +0000 (+0000) Subject: fix undocumented IO::Handle functions as suggested X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=21e970cc3286bbc90a29bffea6823d080d88c86d;p=p5sagit%2Fp5-mst-13.2.git fix undocumented IO::Handle functions as suggested by cj10@cam.ac.uk p4raw-id: //depot/perl@3646 --- diff --git a/ext/IO/lib/IO/Handle.pm b/ext/IO/lib/IO/Handle.pm index 30ee2e5..9b5dd65 100644 --- a/ext/IO/lib/IO/Handle.pm +++ b/ext/IO/lib/IO/Handle.pm @@ -547,18 +547,18 @@ sub format_write { } } +# XXX undocumented sub fcntl { @_ == 3 || croak 'usage: $io->fcntl( OP, VALUE );'; - my ($io, $op, $val) = @_; - my $r = fcntl($io, $op, $val); - defined $r && $r eq "0 but true" ? 0 : $r; + my ($io, $op) = @_; + return fcntl($io, $op, $_[2]); } +# XXX undocumented sub ioctl { @_ == 3 || croak 'usage: $io->ioctl( OP, VALUE );'; - my ($io, $op, $val) = @_; - my $r = ioctl($io, $op, $val); - defined $r && $r eq "0 but true" ? 0 : $r; + my ($io, $op) = @_; + return ioctl($io, $op, $_[2]); } # this sub is for compatability with older releases of IO that used