Open System Services System Calls Reference Manual (G06.25+, H06.03+)

recv(2) OSS System Calls Reference Manual
If the recv() function call fails, the value -1 is returned and errno is set to indicate the error.
ERRORS
If any of the following conditions occurs, the recv() function sets errno to the corresponding
value:
[EBADF] The socket parameter is not a valid le descriptor.
[ECONNRESET]
One of the following conditions occurred:
The transport-provider process for this socket is no longer available.
The TCP/IP subsystem for this socket is no longer available.
The connection was forcibly closed by the peer socket.
The socket can only be closed.
[EFAULT] A user-supplied memory buffer cannot be accessed or written.
[EINTR] A signal interrupted the function before any data was available.
[EINVAL] The MSG_OOB value is specied in the ags parameter and no out-of-band
data is available.
[EIO] An input or output error occurred.
[ENOBUFS] There was not enough buffer space available to complete the call. A retry at a
later time might succeed.
[ENOMEM] Required memory resources were not available. A retry at a later time might
succeed.
[ENOTCONN] A receive operation was attempted on a connection-oriented socket that is not
connected.
[ENOTSOCK] The socket parameter does not refer to a socket.
[EOPNOTSUPP]
The specied value for the ags parameter is not supported for this socket type
or protocol.
[ETIMEDOUT]
A transmission timed out on an active connection.
[EWOULDBLOCK]
The socket le descriptor is marked nonblocking (O_NONBLOCK is set) and
the operation would block.
RELATED INFORMATION
Functions: read(2), recvfrom(2), recvmsg(2), select(2), send(2), sendmsg(2), sendto(2), shut-
down(2), socket(2), write(2).
STANDARDS CONFORMANCE
The HP implementation does not return the errno value [ENOSR].
The following are HP extensions to the XPG4 specication:
The errno value [ECONNRESET] can be returned when the transport-provider process
is unavailable.
614 Hewlett-Packard Company 527186-003