Extensions to Core.Unix
.
fork_exec prog args ~stdin ~stdout ~stderr ~setuid ~setgid
forks a new process that executes the program
in file prog
, with arguments args
. The pid of the new
process is returned immediately; the new process executes
concurrently with the current process.
The function raises EPERM if when using set{gid,uid}
and the user id is
not 0.
The standard input and outputs of the new process are connected
to the descriptors stdin
, stdout
and stderr
.
The close_on_exec flag is cleared from stderr
stdout
and stdin
so it's
safe to pass in fds with close_on_exec
set.
true
than we use PATH to find the process to exec.
setuid
and setgid
do not do a full id drop (e.g.: they save the id in
saved id) when the user does not have the privileges required to setuid to
anyone.Network to host order long, like C.
Host to network order long, like C.
#
bsize
| : int | ; | (* | file system block size | *) |
#
frsize
| : int | ; | (* | fragment size | *) |
#
blocks
| : int | ; | (* | size of fs in frsize units | *) |
#
bfree
| : int | ; | (* | # free blocks | *) |
#
bavail
| : int | ; | (* | # free blocks for non-root | *) |
#
files
| : int | ; | (* | # inodes | *) |
#
ffree
| : int | ; | (* | # free inodes | *) |
#
favail
| : int | ; | (* | # free inodes for non-root | *) |
#
fsid
| : int | ; | (* | file system ID | *) |
#
flag
| : int | ; | (* | mount flags | *) |
#
namemax
| : int | ; | (* | maximum filename length | *) |
get load averages
of_passwd_line
parse a passwd-like line
of_passwd_line_exn
parse a passwd-like line
of_passwd_file
parse a passwd-like file
of_passwd_file_exn
parse a passwd-like file
The CIDR module moved into Core.Unix