diff options
| author | Michael Kerrisk <mtk.manpages@gmail.com> | 2016-09-12 06:00:04 +0100 |
|---|---|---|
| committer | Michael Kerrisk <mtk.manpages@gmail.com> | 2016-09-12 06:00:04 +0100 |
| commit | 8b4be846c762935e70e9395510bb2e99bc46a772 (patch) | |
| tree | 4813405b2470424960c989c2d1a30684a0089445 /man2 | |
| parent | fa1aa3502a2f9554cef6c98f62514abb804201b3 (diff) | |
| download | man-pages-8b4be846c762935e70e9395510bb2e99bc46a772.tar.gz | |
fcntl.2: Make the description of the effect of close-on-exec a little clearer
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Diffstat (limited to 'man2')
| -rw-r--r-- | man2/fcntl.2 | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/man2/fcntl.2 b/man2/fcntl.2 index cbe75e2760..cac8a427cc 100644 --- a/man2/fcntl.2 +++ b/man2/fcntl.2 @@ -144,9 +144,16 @@ Currently, only one such flag is defined: the close-on-exec flag. If the .B FD_CLOEXEC -bit is 0, the file descriptor will remain open across an -.BR execve (2), -otherwise it will be closed. +bit is set, +the file descriptor will automatically be closed during a successful +.BR execve (2). +(If the +.BR execve (2) +fails, the file descriptor is left open.) +If the +.B FD_CLOEXEC +bit is not set, the file descriptor will remain open across an +.BR execve (2). .TP .BR F_GETFD " (\fIvoid\fP)" Return (as the function result) the file descriptor flags; |
