summaryrefslogtreecommitdiff
path: root/doc/libstddjb
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2014-12-18 22:15:03 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2014-12-18 22:15:03 +0000
commit8d548a4be6fd0584f84d107fd83fb18c28ab578f (patch)
treedd9d53b293915d66c61dffc3fc39781f8f48520d /doc/libstddjb
parentc61359571fd3549ed69cd2e3b80e31bc9f9f0514 (diff)
downloadskalibs-8d548a4be6fd0584f84d107fd83fb18c28ab578f.tar.xz
child_spawn1 doc update
Diffstat (limited to 'doc/libstddjb')
-rw-r--r--doc/libstddjb/djbunix.html15
1 files changed, 10 insertions, 5 deletions
diff --git a/doc/libstddjb/djbunix.html b/doc/libstddjb/djbunix.html
index 0d6c89f..37235c1 100644
--- a/doc/libstddjb/djbunix.html
+++ b/doc/libstddjb/djbunix.html
@@ -458,13 +458,20 @@ on systems that support it.
</p>
<p>
-<code> pid_t child_spawn1 (char const *file, char const *const *argv, char const *const *envp, int *fd, int w) </code> <br />
+<code> pid_t child_spawn1_pipe (char const *file, char const *const *argv, char const *const *envp, int *fd, int w) </code> <br />
Like <tt>child_spawn0()</tt>, except that a pipe is created between the child's
stdin (if <em>w</em> is 0) or stdout (if <em>w</em> is nonzero) and the parent.
The parent's end of the pipe will be stored in *<em>fd</em>.
</p>
<p>
+<code> pid_t child_spawn1_socket (char const *file, char const *const *argv, char const *const *envp, int *fd)
+Like <tt>child_spawn0</tt>, 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 *<em>fd</em>.
+</p>
+
+<p>
<code> pid_t child_spawn (char const *file, char const *const *argv, char const *const *envp, int *fds, unsigned int nfds) </code> <br />
More generic spawning function. <em>fds</em> must point to an array of at least <em>nfds</em> ints;
file descriptors reading from or writing to the child will be stored there. The function returns
@@ -472,10 +479,8 @@ file descriptors reading from or writing to the child will be stored there. The
</p>
<ul>
<li> If <em>nfds</em> is 0, then the function behaves like <tt>child_spawn0</tt>, except
-all signals will be reset to the default behaviour in the child </li>
- <li> If <em>nfds</em> is 1, then <em>fds</em>[0] will contain a Unix domain socket
-connected to the child's stdin and stdout. </li>
- <li> If <em>nfds</em> is 2 or more, then <em>fds</em> will contain pipes between the
+all ignored signals will be un-ignored in the child </li>
+ <li> If <em>nfds</em> is 1 or more, then <em>fds</em> will contain pipes between the
child and the parent. The parent will read on even-numbered ones (starting on <em>fds</em>[0])
and write on odd-numbered ones. </li>
</ul>