X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperlopentut.pod;h=5389c1f722cac6acb8d483fc03dee18aa697537a;hb=cc7ef057bab1579c0576d0a578186a6e5ae298e2;hp=6d37fb892b9287f2097cfce02ad477e570b6994f;hpb=1a1931329abb89a33c5409dc3da71dd30c04a0b8;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perlopentut.pod b/pod/perlopentut.pod index 6d37fb8..5389c1f 100644 --- a/pod/perlopentut.pod +++ b/pod/perlopentut.pod @@ -602,7 +602,7 @@ welcome to reopen them if you'd like. open(STDOUT, "> output") || die "can't open output: $!"; -And then these can be read directly or passed on to subprocesses. +And then these can be accessed directly or passed on to subprocesses. This makes it look as though the program were initially invoked with those redirections from the command line. @@ -625,11 +625,11 @@ just in a different process: sub head { my $lines = shift || 20; - return unless $pid = open(STDOUT, "|-"); + return if $pid = open(STDOUT, "|-"); # return if parent die "cannot fork: $!" unless defined $pid; while () { - print; last if --$lines < 0; + print; } exit; } @@ -925,7 +925,7 @@ The two-argument form of C is being used, for example =back -For more detailed discussion about PerlIO see L; +For more detailed discussion about PerlIO see L; for more detailed discussion about Unicode and I/O see L. =head1 SEE ALSO