summaryrefslogtreecommitdiffstats
path: root/contrib/perl5/pod/perltie.pod
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/perl5/pod/perltie.pod')
-rw-r--r--contrib/perl5/pod/perltie.pod11
1 files changed, 7 insertions, 4 deletions
diff --git a/contrib/perl5/pod/perltie.pod b/contrib/perl5/pod/perltie.pod
index cae0a15..6652658 100644
--- a/contrib/perl5/pod/perltie.pod
+++ b/contrib/perl5/pod/perltie.pod
@@ -680,9 +680,12 @@ This method will be called when the handle is read from via the C<read>
or C<sysread> functions.
sub READ {
- $r = shift;
- my($buf,$len,$offset) = @_;
- print "READ called, \$buf=$buf, \$len=$len, \$offset=$offset";
+ my $self = shift;
+ my $$bufref = \$_[0];
+ my(undef,$len,$offset) = @_;
+ print "READ called, \$buf=$bufref, \$len=$len, \$offset=$offset";
+ # add to $$bufref, set $len to number of characters read
+ $len;
}
=item READLINE this
@@ -690,7 +693,7 @@ or C<sysread> functions.
This method will be called when the handle is read from via <HANDLE>.
The method should return undef when there is no more data.
- sub READLINE { $r = shift; "PRINT called $$r times\n"; }
+ sub READLINE { $r = shift; "READLINE called $$r times\n"; }
=item GETC this
OpenPOWER on IntegriCloud