xref: /minix3/minix/man/man2/recv.2 (revision 433d6423c39e34ec4b79c950597bb2d236f886be)
RECV 2
NAME
recv - receive a message through a socket
SYNOPSIS
#include <sys/socket.h> ssize_t recv(int sd, void * msg, size_t msg_len, int flags);

DESCRIPTION
recv() receives a message from another socket. It may only be used with connected sockets. At present, minix doesn't support setting flags to any value other than 0.
RETURN VALUES
On success, this function returns 0. On error, -1 is returned and errno is set.
ERRORS

15 [ENOSYS] The operation is not implemented for the given socket.

15 [EPIPE] The socket is shutdown for reading.

SEE ALSO
recvfrom(2), socket(2), send(2), sendto(2)