mirror of
https://git.FreeBSD.org/src.git
synced 2024-10-19 02:29:40 +00:00
Document posix_spawn_file_actions_addclosefrom_np(3)
Reviewed by: kevans, ngie (previous version) Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D33143
This commit is contained in:
parent
a18ddf7757
commit
78963d796d
@ -463,6 +463,7 @@ MLINKS+=modf.3 modff.3 \
|
|||||||
MLINKS+=popen.3 pclose.3
|
MLINKS+=popen.3 pclose.3
|
||||||
MLINKS+=posix_spawn.3 posix_spawnp.3 \
|
MLINKS+=posix_spawn.3 posix_spawnp.3 \
|
||||||
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addclose.3 \
|
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addclose.3 \
|
||||||
|
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addclosefrom_np.3 \
|
||||||
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_adddup2.3 \
|
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_adddup2.3 \
|
||||||
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addchdir_np.3 \
|
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addchdir_np.3 \
|
||||||
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addfchdir_np.3 \
|
posix_spawn_file_actions_addopen.3 posix_spawn_file_actions_addfchdir_np.3 \
|
||||||
|
@ -422,6 +422,11 @@ in addition to those described by
|
|||||||
This implementation ignores any errors from
|
This implementation ignores any errors from
|
||||||
.Fn close ,
|
.Fn close ,
|
||||||
including trying to close a descriptor that is not open.
|
including trying to close a descriptor that is not open.
|
||||||
|
The ignore extends to any errors from individual file descriptors
|
||||||
|
.Fn close
|
||||||
|
executed as part of the
|
||||||
|
.Fn closefrom
|
||||||
|
action.
|
||||||
.El
|
.El
|
||||||
.Sh SEE ALSO
|
.Sh SEE ALSO
|
||||||
.Xr close 2 ,
|
.Xr close 2 ,
|
||||||
@ -434,6 +439,7 @@ including trying to close a descriptor that is not open.
|
|||||||
.Xr setpgid 2 ,
|
.Xr setpgid 2 ,
|
||||||
.Xr vfork 2 ,
|
.Xr vfork 2 ,
|
||||||
.Xr posix_spawn_file_actions_addclose 3 ,
|
.Xr posix_spawn_file_actions_addclose 3 ,
|
||||||
|
.Xr posix_spawn_file_actions_addclosefrom_np 3 ,
|
||||||
.Xr posix_spawn_file_actions_adddup2 3 ,
|
.Xr posix_spawn_file_actions_adddup2 3 ,
|
||||||
.Xr posix_spawn_file_actions_addopen 3 ,
|
.Xr posix_spawn_file_actions_addopen 3 ,
|
||||||
.Xr posix_spawn_file_actions_addchdir_np 3 ,
|
.Xr posix_spawn_file_actions_addchdir_np 3 ,
|
||||||
|
@ -41,9 +41,10 @@
|
|||||||
.Nm posix_spawn_file_actions_addopen ,
|
.Nm posix_spawn_file_actions_addopen ,
|
||||||
.Nm posix_spawn_file_actions_adddup2 ,
|
.Nm posix_spawn_file_actions_adddup2 ,
|
||||||
.Nm posix_spawn_file_actions_addclose ,
|
.Nm posix_spawn_file_actions_addclose ,
|
||||||
|
.Nm posix_spawn_file_actions_addclosefrom_np ,
|
||||||
.Nm posix_spawn_file_actions_addchdir_np ,
|
.Nm posix_spawn_file_actions_addchdir_np ,
|
||||||
.Nm posix_spawn_file_actions_addfchdir_np
|
.Nm posix_spawn_file_actions_addfchdir_np
|
||||||
.Nd "add open, dup2, close, or chdir/fchdir actions to spawn file actions object"
|
.Nd "add open, dup2, close, closefrom, or chdir/fchdir actions to spawn file actions object"
|
||||||
.Sh LIBRARY
|
.Sh LIBRARY
|
||||||
.Lb libc
|
.Lb libc
|
||||||
.Sh SYNOPSIS
|
.Sh SYNOPSIS
|
||||||
@ -68,6 +69,11 @@
|
|||||||
.Fa "int fildes"
|
.Fa "int fildes"
|
||||||
.Fc
|
.Fc
|
||||||
.Ft int
|
.Ft int
|
||||||
|
.Fo posix_spawn_file_actions_addclosefrom_np
|
||||||
|
.Fa "posix_spawn_file_actions_t * file_actions"
|
||||||
|
.Fa "int from"
|
||||||
|
.Fc
|
||||||
|
.Ft int
|
||||||
.Fo posix_spawn_file_actions_addchdir_np
|
.Fo posix_spawn_file_actions_addchdir_np
|
||||||
.Fa "posix_spawn_file_actions_t *restrict file_actions"
|
.Fa "posix_spawn_file_actions_t *restrict file_actions"
|
||||||
.Fa "const char *restrict path"
|
.Fa "const char *restrict path"
|
||||||
@ -177,6 +183,14 @@ had been called) when a new process is spawned using this file actions
|
|||||||
object.
|
object.
|
||||||
.Pp
|
.Pp
|
||||||
The
|
The
|
||||||
|
.Fn posix_spawn_file_actions_addclosefrom_np
|
||||||
|
function adds a close action to close all file descriptors numerically
|
||||||
|
equal or greater then the argument
|
||||||
|
.Fa from .
|
||||||
|
For each open file descriptor, logically the close action is performed,
|
||||||
|
and any possible errors encountered are ignored.
|
||||||
|
.Pp
|
||||||
|
The
|
||||||
.Fn posix_spawn_file_actions_addchdir_np
|
.Fn posix_spawn_file_actions_addchdir_np
|
||||||
and
|
and
|
||||||
.Fn posix_spawn_file_actions_addfchdir_np
|
.Fn posix_spawn_file_actions_addfchdir_np
|
||||||
@ -238,9 +252,10 @@ is equal to
|
|||||||
A future update of the Standard is expected to require this behavior.
|
A future update of the Standard is expected to require this behavior.
|
||||||
.Pp
|
.Pp
|
||||||
The
|
The
|
||||||
.Fn posix_spawn_file_actions_addchdir_np
|
.Fn posix_spawn_file_actions_addchdir_np ,
|
||||||
|
.Fn posix_spawn_file_actions_addfchdir_np ,
|
||||||
and
|
and
|
||||||
.Fn posix_spawn_file_actions_addfchdir_np
|
.Fn posix_spawn_file_actions_addclosefrom_np
|
||||||
functions are non-standard functions implemented after the similar
|
functions are non-standard functions implemented after the similar
|
||||||
functionality provided by glibc.
|
functionality provided by glibc.
|
||||||
.Sh HISTORY
|
.Sh HISTORY
|
||||||
@ -252,9 +267,10 @@ and
|
|||||||
functions first appeared in
|
functions first appeared in
|
||||||
.Fx 8.0 .
|
.Fx 8.0 .
|
||||||
The
|
The
|
||||||
.Fn posix_spawn_file_actions_addchdir_np
|
.Fn posix_spawn_file_actions_addchdir_np ,
|
||||||
|
.Fn posix_spawn_file_actions_addfchdir_np ,
|
||||||
and
|
and
|
||||||
.Fn posix_spawn_file_actions_addfchdir_np
|
.Fn posix_spawn_file_actions_addclosefrom_np
|
||||||
functions first appeared in
|
functions first appeared in
|
||||||
.Fx 14.0 .
|
.Fx 14.0 .
|
||||||
.Sh AUTHORS
|
.Sh AUTHORS
|
||||||
|
@ -83,6 +83,7 @@ Insufficient memory exists to initialize the spawn file actions object.
|
|||||||
.Sh SEE ALSO
|
.Sh SEE ALSO
|
||||||
.Xr posix_spawn 3 ,
|
.Xr posix_spawn 3 ,
|
||||||
.Xr posix_spawn_file_actions_addclose 3 ,
|
.Xr posix_spawn_file_actions_addclose 3 ,
|
||||||
|
.Xr posix_spawn_file_actions_addclosefrom_np 3 ,
|
||||||
.Xr posix_spawn_file_actions_adddup2 3 ,
|
.Xr posix_spawn_file_actions_adddup2 3 ,
|
||||||
.Xr posix_spawn_file_actions_addopen 3 ,
|
.Xr posix_spawn_file_actions_addopen 3 ,
|
||||||
.Xr posix_spawnp 3
|
.Xr posix_spawnp 3
|
||||||
|
Loading…
Reference in New Issue
Block a user