summaryrefslogtreecommitdiff
path: root/usr/src/man
diff options
context:
space:
mode:
authorRobert Mustacchi <rm@joyent.com>2014-12-03 19:45:58 +0000
committerRobert Mustacchi <rm@joyent.com>2014-12-04 09:08:35 -0800
commita95756817154e8f4dfc0fd0963ce91ea4f5e34fb (patch)
tree31467365f6caad9c3355d560f121db8552e998c0 /usr/src/man
parenta4754370e3396d98214a2a2bbb89a23555b2cff2 (diff)
downloadillumos-joyent-a95756817154e8f4dfc0fd0963ce91ea4f5e34fb.tar.gz
5385 socket I/O related manuals don't document ECONNRESET
Reviewed by: Keith Wesolowski <keith.wesolowski@joyent.com> Reviewed by: Dan McDonald <danmcd@omniti.com> Approved by: Gordon Ross <gwr@nexenta.com>
Diffstat (limited to 'usr/src/man')
-rw-r--r--usr/src/man/man2/read.221
-rw-r--r--usr/src/man/man2/write.221
-rw-r--r--usr/src/man/man3socket/recv.3socket13
-rw-r--r--usr/src/man/man3socket/send.3socket13
-rw-r--r--usr/src/man/man3xnet/recv.3xnet12
-rw-r--r--usr/src/man/man3xnet/send.3xnet13
6 files changed, 56 insertions, 37 deletions
diff --git a/usr/src/man/man2/read.2 b/usr/src/man/man2/read.2
index 71e0211dd2..53a8ccc482 100644
--- a/usr/src/man/man2/read.2
+++ b/usr/src/man/man2/read.2
@@ -9,7 +9,7 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH READ 2 "Sep 13, 2007"
+.TH READ 2 "Dec 03, 2014"
.SH NAME
read, readv, pread \- read from file
.SH SYNOPSIS
@@ -33,7 +33,6 @@ read, readv, pread \- read from file
.fi
.SH DESCRIPTION
-.sp
.LP
The \fBread()\fR function attempts to read \fInbyte\fR bytes from the file
associated with the open file descriptor, \fIfildes\fR, into the buffer pointed
@@ -245,7 +244,6 @@ reflects the prior error. If a hangup occurs on the stream being read,
\fBread()\fR continues to operate normally until the stream head read queue is
empty. Thereafter, it returns \fB0\fR.
.SS "\fBreadv()\fR"
-.sp
.LP
The \fBreadv()\fR function is equivalent to \fBread()\fR, but places the input
data into the \fIiovcnt\fR buffers specified by the members of the \fIiov\fR
@@ -273,7 +271,6 @@ area completely before proceeding to the next.
Upon successful completion, \fBreadv()\fR marks for update the \fBst_atime\fR
field of the file.
.SS "\fBpread()\fR"
-.sp
.LP
The \fBpread()\fR function performs the same action as \fBread()\fR, except
that it reads from a given position in the file without changing the file
@@ -284,13 +281,11 @@ offset value that can be represented in an \fBoff_t\fR for regular files. An
attempt to perform a \fBpread()\fR on a file that is incapable of seeking
results in an error.
.SH RETURN VALUES
-.sp
.LP
Upon successful completion, \fBread()\fR and \fBreadv()\fR return a
non-negative integer indicating the number of bytes actually read. Otherwise,
the functions return \fB\(mi1\fR and set \fBerrno\fR to indicate the error.
.SH ERRORS
-.sp
.LP
The \fBread()\fR, \fBreadv()\fR, and \fBpread()\fR functions will fail if:
.sp
@@ -328,6 +323,17 @@ Message waiting to be read on a stream is not a data message.
.sp
.ne 2
.na
+\fB\fBECONNRESET\fR\fR
+.ad
+.RS 11n
+The \fIfiledes\fR argument refers to a connection oriented socket and the
+connection was forcibly closed by the peer and is no longer valid. I/O can no
+longer be performed to \fIfiledes\fR.
+.RE
+
+.sp
+.ne 2
+.na
\fB\fBEDEADLK\fR\fR
.ad
.RS 11n
@@ -478,12 +484,10 @@ The \fIfildes\fR argument is associated with a pipe or FIFO.
.RE
.SH USAGE
-.sp
.LP
The \fBpread()\fR function has a transitional interface for 64-bit file
offsets. See \fBlf64\fR(5).
.SH ATTRIBUTES
-.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
@@ -503,7 +507,6 @@ Standard See \fBstandards\fR(5).
.TE
.SH SEE ALSO
-.sp
.LP
\fBIntro\fR(2), \fBchmod\fR(2), \fBcreat\fR(2), \fBdup\fR(2), \fBfcntl\fR(2),
\fBgetmsg\fR(2), \fBioctl\fR(2), \fBlseek\fR(2), \fBopen\fR(2), \fBpipe\fR(2),
diff --git a/usr/src/man/man2/write.2 b/usr/src/man/man2/write.2
index 78309c766a..cf2dd34fac 100644
--- a/usr/src/man/man2/write.2
+++ b/usr/src/man/man2/write.2
@@ -9,7 +9,7 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH WRITE 2 "Jan 29, 2008"
+.TH WRITE 2 "Dec 03, 2014"
.SH NAME
write, pwrite, writev \- write on a file
.SH SYNOPSIS
@@ -34,7 +34,6 @@ write, pwrite, writev \- write on a file
.fi
.SH DESCRIPTION
-.sp
.LP
The \fBwrite()\fR function attempts to write \fInbyte\fR bytes from the buffer
pointed to by \fIbuf\fR to the file associated with the open file descriptor,
@@ -258,7 +257,6 @@ processed an asynchronous error before the call. In this case, the value of
\fBerrno\fR does not reflect the result of \fBwrite()\fR or \fBwritev()\fR but
reflects the prior error.
.SS "\fBpwrite()\fR"
-.sp
.LP
The \fBpwrite()\fR function is equivalent to \fBwrite()\fR, except that it
writes into a given position and does not change the file offset (regardless of
@@ -266,7 +264,6 @@ whether \fBO_APPEND\fR is set). The first three arguments to \fBpwrite()\fR are
the same as \fBwrite()\fR, with the addition of a fourth argument \fIoffset\fR
for the desired position inside the file.
.SS "\fBwritev()\fR"
-.sp
.LP
The \fBwritev()\fR function performs the same action as \fBwrite()\fR, but
gathers the output data from the \fIiovcnt\fR buffers specified by the members
@@ -300,7 +297,6 @@ have no other effect. For other file types, the behavior is unspecified.
If the sum of the \fBiov_len\fR values is greater than \fBSSIZE_MAX\fR, the
operation fails and no data is transferred.
.SH RETURN VALUES
-.sp
.LP
Upon successful completion, \fBwrite()\fR returns the number of bytes actually
written to the file associated with \fIfildes\fR. This number is never greater
@@ -312,7 +308,6 @@ Upon successful completion, \fBwritev()\fR returns the number of bytes actually
written. Otherwise, it returns \fB\(mi1\fR, the file-pointer remains
unchanged, and \fBerrno\fR is set to indicate an error.
.SH ERRORS
-.sp
.LP
The \fBwrite()\fR, \fBpwrite()\fR, and \fBwritev()\fR functions will fail if:
.sp
@@ -340,6 +335,17 @@ The \fIfildes\fR argument is not a valid file descriptor open for writing.
.sp
.ne 2
.na
+\fB\fBECONNRESET\fR\fR
+.ad
+.RS 11n
+The \fIfiledes\fR argument refers to a connection oriented socket and the
+connection was forcibly closed by the peer and is no longer valid. I/O can no
+longer be performed to \fIfiledes\fR.
+.RE
+
+.sp
+.ne 2
+.na
\fB\fBEDEADLK\fR\fR
.ad
.RS 11n
@@ -557,12 +563,10 @@ overflowed an \fBssize_t\fR.
.RE
.SH USAGE
-.sp
.LP
The \fBpwrite()\fR function has a transitional interface for 64-bit file
offsets. See \fBlf64\fR(5).
.SH ATTRIBUTES
-.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
@@ -582,7 +586,6 @@ Standard See \fBstandards\fR(5).
.TE
.SH SEE ALSO
-.sp
.LP
\fBIntro\fR(2), \fBchmod\fR(2), \fBcreat\fR(2), \fBdup\fR(2), \fBfcntl\fR(2),
\fBgetrlimit\fR(2), \fBioctl\fR(2), \fBlseek\fR(2), \fBopen\fR(2),
diff --git a/usr/src/man/man3socket/recv.3socket b/usr/src/man/man3socket/recv.3socket
index 5f987e43f0..870da95019 100644
--- a/usr/src/man/man3socket/recv.3socket
+++ b/usr/src/man/man3socket/recv.3socket
@@ -4,7 +4,7 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH RECV 3SOCKET "Aug 20, 2007"
+.TH RECV 3SOCKET "Dec 03, 2014"
.SH NAME
recv, recvfrom, recvmsg \- receive a message from a socket
.SH SYNOPSIS
@@ -135,6 +135,17 @@ The \fIs\fR file descriptor is invalid.
.sp
.ne 2
.na
+\fB\fBECONNRESET\fR\fR
+.ad
+.RS 16n
+The \fIs\fR argument refers to a connection oriented socket and the connection
+was forcibly closed by the peer and is no longer valid. I/O can no longer be
+performed to \fIfiledes\fR.
+.RE
+
+.sp
+.ne 2
+.na
\fB\fBEINVAL\fR\fR
.ad
.RS 16n
diff --git a/usr/src/man/man3socket/send.3socket b/usr/src/man/man3socket/send.3socket
index b37df998f7..2d66baa5ce 100644
--- a/usr/src/man/man3socket/send.3socket
+++ b/usr/src/man/man3socket/send.3socket
@@ -4,7 +4,7 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
.\" See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with
.\" the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH SEND 3SOCKET "Aug 31, 2009"
+.TH SEND 3SOCKET "Dec 03, 2014"
.SH NAME
send, sendto, sendmsg \- send a message from a socket
.SH SYNOPSIS
@@ -104,6 +104,17 @@ under the following conditions:
.sp
.ne 2
.na
+\fB\fBECONNRESET\fR\fR
+.ad
+.RS 16n
+The \fIs\fR argument refers to a connection oriented socket and the connection
+was forcibly closed by the peer and is no longer valid. I/O can no longer be
+performed to \fIfiledes\fR.
+.RE
+
+.sp
+.ne 2
+.na
\fB\fBEINTR\fR\fR
.ad
.RS 16n
diff --git a/usr/src/man/man3xnet/recv.3xnet b/usr/src/man/man3xnet/recv.3xnet
index ed8488e9c8..8f9d010c01 100644
--- a/usr/src/man/man3xnet/recv.3xnet
+++ b/usr/src/man/man3xnet/recv.3xnet
@@ -7,7 +7,7 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH RECV 3XNET "Jun 10, 2002"
+.TH RECV 3XNET "Dec 03, 2014"
.SH NAME
recv \- receive a message from a connected socket
.SH SYNOPSIS
@@ -20,7 +20,6 @@ recv \- receive a message from a connected socket
.fi
.SH DESCRIPTION
-.sp
.LP
The \fBrecv()\fR function receives a message from a connection-mode or
connectionless-mode socket. It is normally used with connected sockets because
@@ -118,7 +117,6 @@ no messages are available at the socket and \fBO_NONBLOCK\fR is set on the
socket's file descriptor, \fBrecv()\fR fails and sets \fBerrno\fR to
\fBEAGAIN\fR or \fBEWOULDBLOCK\fR.
.SH USAGE
-.sp
.LP
The \fBrecv()\fR function is identical to \fBrecvfrom\fR(3XNET) with a zero
\fIaddress_len\fR argument, and to \fBread()\fR if no flags are used.
@@ -127,14 +125,12 @@ The \fBrecv()\fR function is identical to \fBrecvfrom\fR(3XNET) with a zero
The \fBselect\fR(3C) and \fBpoll\fR(2) functions can be used to determine when
data is available to be received.
.SH RETURN VALUES
-.sp
.LP
Upon successful completion, \fBrecv()\fR returns the length of the message in
bytes. If no messages are available to be received and the peer has performed
an orderly shutdown, \fBrecv()\fR returns 0. Otherwise, -1 is returned and
\fBerrno\fR is set to indicate the error.
.SH ERRORS
-.sp
.LP
The \fBrecv()\fR function will fail if:
.sp
@@ -168,7 +164,9 @@ The \fIsocket\fR argument is not a valid file descriptor.
\fB\fBECONNRESET\fR\fR
.ad
.RS 15n
-A connection was forcibly closed by a peer.
+The \fIsocket\fR argument refers to a connection oriented socket and the
+connection was forcibly closed by the peer and is no longer valid. I/O can no
+longer be performed to \fIfiledes\fR.
.RE
.sp
@@ -277,7 +275,6 @@ complete.
.RE
.SH ATTRIBUTES
-.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
@@ -295,7 +292,6 @@ MT-Level MT-Safe
.TE
.SH SEE ALSO
-.sp
.LP
\fBpoll\fR(2), \fBrecvmsg\fR(3XNET), \fBrecvfrom\fR(3XNET), \fBselect\fR(3C),
\fBsend\fR(3XNET), \fBsendmsg\fR(3XNET), \fBsendto\fR(3XNET),
diff --git a/usr/src/man/man3xnet/send.3xnet b/usr/src/man/man3xnet/send.3xnet
index c2a697d0f2..c518b11ddd 100644
--- a/usr/src/man/man3xnet/send.3xnet
+++ b/usr/src/man/man3xnet/send.3xnet
@@ -7,7 +7,7 @@
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
-.TH SEND 3XNET "Nov 1, 2003"
+.TH SEND 3XNET "Dec 3, 2014"
.SH NAME
send \- send a message on a socket
.SH SYNOPSIS
@@ -20,7 +20,6 @@ send \- send a message on a socket
.fi
.SH PARAMETERS
-.sp
.ne 2
.na
\fB\fIsocket\fR\fR
@@ -77,7 +76,6 @@ significance and semantics of out-of-band data are protocol-specific.
.RE
.SH DESCRIPTION
-.sp
.LP
The \fBsend()\fR function initiates transmission of a message from the
specified socket to its peer. The \fBsend()\fR function sends a message only
@@ -106,17 +104,14 @@ is possible to send more data.
The socket in use may require the process to have appropriate privileges to use
the \fBsend()\fR function.
.SH USAGE
-.sp
.LP
The \fBsend()\fR function is identical to \fBsendto\fR(3XNET) with a null
pointer \fIdest_len\fR argument, and to \fBwrite()\fR if no flags are used.
.SH RETURN VALUES
-.sp
.LP
Upon successful completion, \fBsend()\fR returns the number of bytes sent.
Otherwise, \(mi1 is returned and \fBerrno\fR is set to indicate the error.
.SH ERRORS
-.sp
.LP
The \fBsend()\fR function will fail if:
.sp
@@ -148,7 +143,9 @@ The \fIsocket\fR argument is not a valid file descriptor.
\fB\fBECONNRESET\fR\fR
.ad
.RS 16n
-A connection was forcibly closed by a peer.
+The \fIsocket\fR argument refers to a connection oriented socket and the
+connection was forcibly closed by the peer and is no longer valid. I/O can no
+longer be performed to \fIfiledes\fR.
.RE
.sp
@@ -285,7 +282,6 @@ complete.
.RE
.SH ATTRIBUTES
-.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp
@@ -303,7 +299,6 @@ MT-Level MT-Safe
.TE
.SH SEE ALSO
-.sp
.LP
\fBconnect\fR(3XNET), \fBgetsockopt\fR(3XNET), \fBpoll\fR(2),
\fBrecv\fR(3XNET), \fBrecvfrom\fR(3XNET), \fBrecvmsg\fR(3XNET),