]> git.ozlabs.org Git - ccan/blobdiff - ccan/io/benchmarks/run-loop.c
ccan/io: io_close_cb()
[ccan] / ccan / io / benchmarks / run-loop.c
index b0d383e89b7c2310f0c5a6acf42babfc808d9f3e..ef01cf6a94663597dec0b4f7d0fe63bbe9c02f7a 100644 (file)
@@ -23,7 +23,7 @@ static struct io_plan poke_writer(struct io_conn *conn, struct buffer *buf)
        assert(conn == buf->reader);
 
        if (buf->iters == NUM_ITERS)
-               return io_close(conn, NULL);
+               return io_close();
 
        /* You write. */
        io_wake(buf->writer,
@@ -41,7 +41,7 @@ static struct io_plan poke_reader(struct io_conn *conn, struct buffer *buf)
                io_read(&buf->buf, sizeof(buf->buf), poke_writer, buf));
 
        if (++buf->iters == NUM_ITERS)
-               return io_close(conn, NULL);
+               return io_close();
 
        /* I'll wait until you tell me to write. */
        return io_idle();