X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=ccan%2Fio%2Ftest%2Frun-13-all-idle.c;h=7896b14f4e036913f2ae67feca4f3903e580b024;hb=0fbc79090f9ff5bc1caf8c0f0f05525a05f2e82d;hp=b6a52a55790da4aec03d35e53eede81b6990e2cf;hpb=02388bfc242abbd33c7ba64b2c32d425f5359b67;p=ccan diff --git a/ccan/io/test/run-13-all-idle.c b/ccan/io/test/run-13-all-idle.c index b6a52a55..7896b14f 100644 --- a/ccan/io/test/run-13-all-idle.c +++ b/ccan/io/test/run-13-all-idle.c @@ -7,9 +7,9 @@ #include #include -static struct io_op *start(struct io_conn *conn, void *unused) +static struct io_plan *setup_waiter(struct io_conn *conn, int *status) { - return io_idle(conn); + return io_wait(conn, status, io_close_cb, NULL); } int main(void) @@ -22,8 +22,8 @@ int main(void) int fds[2]; ok1(pipe(fds) == 0); - io_new_conn(fds[0], start, NULL, NULL); - io_loop(); + io_new_conn(NULL, fds[0], setup_waiter, &status); + io_loop(NULL, NULL); exit(1); }