OSDN Git Service

(split) LDP: Update original to LDP v3.40.
[linuxjm/LDP_man-pages.git] / original / man2 / send.2
index c99b77a..6f71300 100644 (file)
@@ -35,7 +35,7 @@
 .\" Modified Oct 2003 by aeb
 .\" Modified 2004-07-01 by mtk
 .\"
-.TH SEND 2 2009-02-23 "Linux" "Linux Programmer's Manual"
+.TH SEND 2 2012-04-23 "Linux" "Linux Programmer's Manual"
 .SH NAME
 send, sendto, sendmsg \- send a message on a socket
 .SH SYNOPSIS
@@ -72,7 +72,7 @@ and
 .BR write (2)
 is the presence of
 .IR flags .
-With zero
+With zero
 .I flags
 argument,
 .BR send ()
@@ -250,7 +250,7 @@ struct msghdr {
     struct iovec *msg_iov;        /* scatter/gather array */
     size_t        msg_iovlen;     /* # elements in msg_iov */
     void         *msg_control;    /* ancillary data, see below */
-    socklen_t     msg_controllen; /* ancillary data buffer len */
+    size_t        msg_controllen; /* ancillary data buffer len */
     int           msg_flags;      /* flags on received message */
 };
 .fi
@@ -282,12 +282,15 @@ may be generated and returned from the underlying protocol modules;
 see their respective manual pages.
 .TP
 .B EACCES
-(For Unix domain sockets, which are identified by pathname)
+(For UNIX domain sockets, which are identified by pathname)
 Write permission is denied on the destination socket file,
 or search permission is denied for one of the directories
 the path prefix.
 (See
 .BR path_resolution (7).)
+.sp
+(For UDP sockets) An attempt was made to send to a
+network/broadcast address as though it was a unicast address.
 .TP
 .BR EAGAIN " or " EWOULDBLOCK
 .\" Actually EAGAIN on Linux
@@ -369,11 +372,13 @@ POSIX.1-2001 only describes the
 and
 .B MSG_EOR
 flags.
+POSIX.1-2008 adds a specification of
+.BR MSG_NOSIGNAL .
 The
 .B MSG_CONFIRM
 flag is a Linux extension.
 .SH NOTES
-The prototypes given above follow the Single Unix Specification,
+The prototypes given above follow the Single UNIX Specification,
 as glibc2 also does; the
 .I flags
 argument was \fIint\fP in 4.x BSD, but \fIunsigned int\fP in libc4 and libc5;
@@ -392,13 +397,18 @@ field of the
 .I msghdr
 structure should be typed as
 .IR socklen_t ,
-but glibc currently (2.4) types it as
+but glibc currently types it as
 .IR size_t .
 .\" glibc bug raised 12 Mar 2006
 .\" http://sourceware.org/bugzilla/show_bug.cgi?id=2448
 .\" The problem is an underlying kernel issue: the size of the
 .\" __kernel_size_t type used to type this field varies
 .\" across architectures, but socklen_t is always 32 bits.
+
+See
+.BR sendmmsg(2)
+for information about a Linux-specific system call
+that can be used to transmit multiple datagrams in a single call.
 .SH BUGS
 Linux may return
 .B EPIPE
@@ -415,6 +425,7 @@ is shown in
 .BR recv (2),
 .BR select (2),
 .BR sendfile (2),
+.BR sendmmsg (2),
 .BR shutdown (2),
 .BR socket (2),
 .BR write (2),