summaryrefslogtreecommitdiffstats
path: root/lib/libc/sys/fcntl.2
diff options
context:
space:
mode:
authorkib <kib@FreeBSD.org>2012-07-27 10:41:53 +0000
committerkib <kib@FreeBSD.org>2012-07-27 10:41:53 +0000
commit4e7839007ab707452aab4262d6fee9846bb28767 (patch)
tree018dea469e87f3a8a46f326de6555aabd3b6bafa /lib/libc/sys/fcntl.2
parent5a2e16924f3798ee7f3bf930c0d43f38f18a69dd (diff)
downloadFreeBSD-src-4e7839007ab707452aab4262d6fee9846bb28767.zip
FreeBSD-src-4e7839007ab707452aab4262d6fee9846bb28767.tar.gz
Document F_DUP2FD_CLOEXEC.
MFC after: 1 week
Diffstat (limited to 'lib/libc/sys/fcntl.2')
-rw-r--r--lib/libc/sys/fcntl.218
1 files changed, 14 insertions, 4 deletions
diff --git a/lib/libc/sys/fcntl.2 b/lib/libc/sys/fcntl.2
index 0844e87..63d6510 100644
--- a/lib/libc/sys/fcntl.2
+++ b/lib/libc/sys/fcntl.2
@@ -28,7 +28,7 @@
.\" @(#)fcntl.2 8.2 (Berkeley) 1/12/94
.\" $FreeBSD$
.\"
-.Dd July 18, 2012
+.Dd July 27, 2012
.Dt FCNTL 2
.Os
.Sh NAME
@@ -54,7 +54,7 @@ Depending on the value of
.Fn fcntl
can take an additional third argument
.Fa "int arg" .
-.Bl -tag -width F_DUPFD_CLOEXEC
+.Bl -tag -width F_DUP2FD_CLOEXEC
.It Dv F_DUPFD
Return a new descriptor as follows:
.Pp
@@ -94,13 +94,23 @@ It is functionally equivalent to
.Bd -literal -offset indent
dup2(fd, arg)
.Ed
+.It Dv F_DU2PFD_CLOEXEC
+Like
+.Dv F_DUP2FD ,
+but the
+.Dv FD_CLOEXEC
+flag associated with the new file descriptor is set.
.Pp
The
.Dv F_DUP2FD
-constant is not portable, so it should not be used if portability is needed.
+and
+.Dv F_DUP2DF_CLOEXEC
+constants are not portable, so they should not be used if
+portability is needed.
Use
.Fn dup2
-instead.
+instead of
+.Dv F_DUP2FD .
.It Dv F_GETFD
Get the close-on-exec flag associated with the file descriptor
.Fa fd
OpenPOWER on IntegriCloud