From 8ba811fb48d666a23d60a5ce3a947dcac7baf6ea Mon Sep 17 00:00:00 2001
From: Laurent Bercot
- pid_t child_spawn0 (char const *file, char const *const *argv, char const *const *envp)
-Forks and executes a child as with exec_ae(file, argv, envp).
-Returns 0 if it fails, and the pid of the child if it succeeds.
-Implemented via posix_spawn()
-on systems that support it.
+The child_spawn family of functions has been moved to the
+skalibs/cspawn.h header.
- pid_t child_spawn1_pipe (char const *file, char const *const *argv, char const *const *envp, int *fd, int w)
-Like child_spawn0(), except that a pipe is created between the child's
-stdin (if w is 0) or stdout (if w is nonzero) and the parent.
-The parent's end of the pipe will be stored in *fd.
-
- pid_t child_spawn1_socket (char const *file, char const *const *argv, char const *const *envp, int *fd)
-Like child_spawn0, except that a socket is created between the parent
-and the child. Both the child's stdin and stdout point to the socket; the parent has
-its end of the socket available in *fd.
-
- pid_t child_spawn2 (char const *file, char const *const *argv, char const *const *envp, int *fds)
-Like child_spawn0(), except that two pipes are created between the
-parent and the child. fds must point to an array of 2 ints: this
-array is read as well as written by child_spawn2(). On function
-call, the numbers in fds must describe what fds should be used
-in the child to contain the communication pipes (for instance, if the child
-will read from its parent on stdin and writes to its parent on stdout, fds
-must contain 0 and 1). On function return, fds contains the
-descriptors for the pipes that read from / write to the child.
-
- pid_t child_spawn (char const *file, char const *const *argv, char const *const *envp, int *fds, unsigned int nfds)
-More generic spawning function. fds must point to an array of at least nfds ints;
-file descriptors reading from or writing to the child will be stored there. The function returns
-0 on failure or the pid of the child on success.
-
-- cgit v1.3.1