This patch fixes the type of msg_controllen in the struct msghdr
definition given in send.2 and recv.2 to match the definition in
glibc and the kernel.
Signed-off-by: Michael Kerrisk <mtk@konstanz.(none)>
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "non-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Fix some formatting typos
* the period should be in Roman font
* .RP does not exist, it should be .RB
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The 'msghdr' structure includes a field of type 'iovec',
so show the definition of that structure in this page.
Reported-by: Johannes Stezenbach <js@sig21.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
For a non-blocking socket, POSIX.1-2001/2008 allow either
EAGAIN or EWOULDBLOCK to be returned in cases where a call
would have blocked. Although these constants are defined
with the same value on most Linux architectures (PA-RISC
is the exception), POSIX.1 does not require them to have
the same value. Therefore, a portable application using
the sockets API should test for both errors when checking
this case.
(NB POSIX.1 only mentions EWOULDBLOCK in the context of
the sockets interfaces.)
Change made after a note cross-posted on linux-arch@vger,
http://thread.gmane.org/gmane.linux.debian.ports.hppa/5615
and a suggestion for write(2) from Carlos O'Donell
Reported-by: Carlos O'Donell <carlos@systemhalted.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
If the recvfrom() returned address is truncated, the 'fromlen'
argument indicates the actual size of the address, rather than
a count of the number of bytes in the truncated buffer.
Also clarify that the 'from' argument can be NULL, in which
case 'fromlen' should is unused, and should also be NULL.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Many sockets man pages use the name 'sockfd' already.
For consistency, changes the others to do so as well.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Internet datagram (since Linux 2.4.27/2.6.8),
and netlink (since Linux 2.6.22) sockets support
the MSG_TRUNC flag for recv(2).
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>