.\" Copyright (c) 1983, 1991 The Regents of the University of California.
.\" All rights reserved.
.\"
+.\" %%%LICENSE_START(BSD_4_CLAUSE_UCB)
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
+.\" %%%LICENSE_END
.\"
.\" Modified 1993-07-24 by Rik Faith <faith@cs.unc.edu>
.\" Modified 1996-10-22 by Eric S. Raymond <esr@thyrsus.com>
.\" Modified Oct 2003 by aeb
.\" Modified 2004-07-01 by mtk
.\"
-.TH SEND 2 2012-02-27 "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
.B SOCK_DGRAM
and
.B SOCK_RAW
-sockets and currently only implemented for IPv4 and IPv6.
+sockets and currently implemented only for IPv4 and IPv6.
See
.BR arp (7)
for details.
.TP
.B MSG_DONTROUTE
-Don't use a gateway to send out the packet, only send to hosts on
+Don't use a gateway to send out the packet, send to hosts only on
directly connected networks.
This is usually used only
by diagnostic or routing programs.
-This is only defined for protocol
+This is defined only for protocol
families that route; packet sockets don't.
.TP
.BR MSG_DONTWAIT " (since Linux 2.2)"
Since Linux 2.6, this flag is also supported for UDP sockets, and informs
the kernel to package all of the data sent in calls with this flag set
-into a single datagram which is only transmitted when a call is performed
+into a single datagram which is transmitted only when a call is performed
that does not specify this flag.
(See also the
.B UDP_CORK
.\" Send file descriptors and user credentials using the
.\" msg_control* fields.
.\" The flags returned in msg_flags.
-.SH "RETURN VALUE"
+.SH RETURN VALUE
On success, these calls return the number of characters sent.
On error, \-1 is returned, and
.I errno
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
unless
.B MSG_NOSIGNAL
is set.
-.SH "CONFORMING TO"
+.SH CONFORMING TO
4.4BSD, SVr4, POSIX.1-2001.
These function calls appeared in 4.2BSD.
.LP
-POSIX.1-2001 only describes the
+POSIX.1-2001 describes only the
.B MSG_OOB
and
.B MSG_EOR
.\" across architectures, but socklen_t is always 32 bits.
See
-.BR sendmmsg(2)
+.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
.BR sendto ()
is shown in
.BR getaddrinfo (3).
-.SH "SEE ALSO"
+.SH SEE ALSO
.BR fcntl (2),
.BR getsockopt (2),
.BR recv (2),