diff options
author | Gisle Aas <gisle@aas.no> | 2003-08-04 06:25:28 -0700 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2003-08-05 06:21:47 +0000 |
commit | 2c2cb4122eb316f028f8d8303287fd2a55536c62 (patch) | |
tree | d5cf9503bcd104763ec85dce5d52de676141b94e /pod/perlapio.pod | |
parent | 90d1fc5d9717d620a09747684b1a0f435223e344 (diff) | |
download | perl-2c2cb4122eb316f028f8d8303287fd2a55536c62.tar.gz |
PerlIO_{read,write} return value doc patch
Message-ID: <lr4r0xuq4n.fsf@caliper.activestate.com>
p4raw-id: //depot/perl@20489
Diffstat (limited to 'pod/perlapio.pod')
-rw-r--r-- | pod/perlapio.pod | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/pod/perlapio.pod b/pod/perlapio.pod index 98fc53d85f..10b8dc554e 100644 --- a/pod/perlapio.pod +++ b/pod/perlapio.pod @@ -160,9 +160,14 @@ so it is (currently) legal to use C<printf(fmt,...)> in perl sources. =item B<PerlIO_read(f,buf,count)>, B<PerlIO_write(f,buf,count)> -These correspond to fread() and fwrite(). Note that arguments are -different, there is only one "count" and order has "file" -first. Returns a byte count if successful (which may be zero or +These correspond functionally to fread() and fwrite() but the +arguments and return values are different. The PerlIO_read() and +PerlIO_write() signatures have been modeled on the more sane low level +read() and write() functions instead: The "file" argument is passed +first, there is only one "count", and the return value can distinguish +between error and C<EOF>. + +Returns a byte count if successful (which may be zero or positive), returns negative value and sets C<errno> on error. Depending on implementation C<errno> may be C<EINTR> if operation was interrupted by a signal. |