recv.2: RETURN VALUE: mention that 'errno' is set on error

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2013-04-19 08:32:47 +02:00
parent 47a979088f
commit eb20a4fb40
1 changed files with 4 additions and 1 deletions

View File

@ -38,7 +38,7 @@
.\" Modified 1998,1999 by Andi Kleen .\" Modified 1998,1999 by Andi Kleen
.\" 2001-06-19 corrected SO_EE_OFFENDER, bug report by James Hawtin .\" 2001-06-19 corrected SO_EE_OFFENDER, bug report by James Hawtin
.\" .\"
.TH RECV 2 2012-12-21 "Linux" "Linux Programmer's Manual" .TH RECV 2 2013-04-19 "Linux" "Linux Programmer's Manual"
.SH NAME .SH NAME
recv, recvfrom, recvmsg \- receive a message from a socket recv, recvfrom, recvmsg \- receive a message from a socket
.SH SYNOPSIS .SH SYNOPSIS
@ -388,6 +388,9 @@ error queue.
.SH RETURN VALUE .SH RETURN VALUE
These calls return the number of bytes received, or \-1 These calls return the number of bytes received, or \-1
if an error occurred. if an error occurred.
In the event of an error,
.I errno
is set to indicate the error.
The return value will be 0 when the The return value will be 0 when the
peer has performed an orderly shutdown. peer has performed an orderly shutdown.
.SH ERRORS .SH ERRORS