X-Git-Url: https://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=ccan%2Fio%2Ftest%2Frun-09-connect.c;h=124b6a1f70e715f08a3014a8cee72372611ce575;hp=8f57f00d8e0f4a6474f63280b20f3b3b6946883d;hb=318f717e34e4735e5397bee24dbbee69205be82b;hpb=cdffdf5d61f8330cfc3467e73a84876eb3928e9b diff --git a/ccan/io/test/run-09-connect.c b/ccan/io/test/run-09-connect.c index 8f57f00d..124b6a1f 100644 --- a/ccan/io/test/run-09-connect.c +++ b/ccan/io/test/run-09-connect.c @@ -6,7 +6,9 @@ #include #include -#ifndef PORT +#ifdef DEBUG_CONN +#define PORT "64009" +#else #define PORT "65009" #endif @@ -33,6 +35,9 @@ static struct io_plan *connected(struct io_conn *conn, struct data *d2) static struct io_plan *init_conn(struct io_conn *conn, struct data *d) { +#ifdef DEBUG_CONN + io_set_debug(conn, true); +#endif ok1(d->state == 0); d->state++; io_close_listener(l); @@ -99,7 +104,7 @@ int main(void) addrinfo->ai_protocol); ok1(io_new_conn(NULL, fd, setup_connect, addrinfo)); - ok1(io_loop() == NULL); + ok1(io_loop(NULL, NULL) == NULL); ok1(d->state == 2); ok1(d2->state == 2);