summaryrefslogtreecommitdiff
path: root/src/libunixonacid/textclient_startf.c
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2020-10-26 21:31:16 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2020-10-26 21:31:16 +0000
commitbc714f8001edbb26ebf07411cf92e9ba2f756b35 (patch)
treee0812fa851135a518209640876b1dc4dd9b7dfad /src/libunixonacid/textclient_startf.c
parent7530e8cdd506ecec1f4ad3bbd55f94de5a6d63ac (diff)
downloadskalibs-bc714f8001edbb26ebf07411cf92e9ba2f756b35.tar.xz
Refactor textmessage/textclient with channel creation around ancil_*
Diffstat (limited to 'src/libunixonacid/textclient_startf.c')
-rw-r--r--src/libunixonacid/textclient_startf.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/libunixonacid/textclient_startf.c b/src/libunixonacid/textclient_startf.c
index 20ebe33..fc871fd 100644
--- a/src/libunixonacid/textclient_startf.c
+++ b/src/libunixonacid/textclient_startf.c
@@ -21,10 +21,11 @@ int textclient_startf (textclient_t *a, char const *const *argv, char const *con
textmessage_sender_init(&a->syncout, fd[1]) ;
a->pid = pid ;
a->options = options ;
- if (!textclient_exchange(a, before, beforelen, &v, deadline, stamp)) goto err ;
- if (v.iov_len != afterlen || memcmp(v.iov_base, after, afterlen)) goto errproto ;
+ if (!textclient_timed_send(a, before, beforelen, deadline, stamp)) goto err ;
if (sanitize_read(textmessage_timed_receive(&a->asyncin, &v, deadline, stamp)) <= 0) goto err ;
if (v.iov_len != afterlen || memcmp(v.iov_base, after, afterlen)) goto errproto ;
+ if (!textclient_timed_get(a, &v, deadline, stamp)) goto err ;
+ if (v.iov_len != afterlen || memcmp(v.iov_base, after, afterlen)) goto errproto ;
return 1 ;
errproto: