diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2018-01-03 12:09:01 +0000 |
---|---|---|
committer | Laurent Bercot <ska-skaware@skarnet.org> | 2018-01-03 12:09:01 +0000 |
commit | 6b69c1f8921d0f692e9aaa65d21349e01ecc670b (patch) | |
tree | 0e1dec679b84fb933504063516c8ab98f5765298 /src/libunixonacid/textclient_startf.c | |
parent | ed40369c8610914085d568ec57701a035bf8dd29 (diff) | |
download | skalibs-6b69c1f8921d0f692e9aaa65d21349e01ecc670b.tar.xz |
Add child_spawn3, make textclient_startf use it
Diffstat (limited to 'src/libunixonacid/textclient_startf.c')
-rw-r--r-- | src/libunixonacid/textclient_startf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libunixonacid/textclient_startf.c b/src/libunixonacid/textclient_startf.c index fd724cd..6a6f0fc 100644 --- a/src/libunixonacid/textclient_startf.c +++ b/src/libunixonacid/textclient_startf.c @@ -12,8 +12,8 @@ int textclient_startf (textclient_t *a, char const *const *argv, char const *const *envp, uint32_t options, char const *before, size_t beforelen, char const *after, size_t afterlen, tain_t const *deadline, tain_t *stamp) { struct iovec v ; - int fd[3] ; - pid_t pid = child_spawn(argv[0], argv, envp, fd, 3) ; + int fd[3] = { 0, 1 } ; + pid_t pid = child_spawn3(argv[0], argv, envp, fd) ; if (!pid) return 0 ; textmessage_receiver_init(&a->syncin, fd[0], a->syncbuf, TEXTCLIENT_BUFSIZE, TEXTMESSAGE_MAXLEN) ; textmessage_receiver_init(&a->asyncin, fd[2], a->asyncbuf, TEXTCLIENT_BUFSIZE, TEXTMESSAGE_MAXLEN) ; |