aboutsummaryrefslogtreecommitdiff
path: root/src/supplemental/http/http_conn.c
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2020-01-08 20:34:26 -0800
committerGarrett D'Amore <garrett@damore.org>2020-01-08 21:16:30 -0800
commitb21d7805523a407a14567017edbdef57ca81781f (patch)
treee07f08bdc047ee4dfb057b670766e3de5bf2f981 /src/supplemental/http/http_conn.c
parent8479b4c8861c77cfd9eb64e724615605bdd1cbcb (diff)
downloadnng-b21d7805523a407a14567017edbdef57ca81781f.tar.gz
nng-b21d7805523a407a14567017edbdef57ca81781f.tar.bz2
nng-b21d7805523a407a14567017edbdef57ca81781f.zip
fixes #1094 Consider in-lining task and aio
This only does it for rep, but it also has changes that should increase the overall test coverage for the REP protocol
Diffstat (limited to 'src/supplemental/http/http_conn.c')
-rw-r--r--src/supplemental/http/http_conn.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/supplemental/http/http_conn.c b/src/supplemental/http/http_conn.c
index 1fc2c34e..583f5eee 100644
--- a/src/supplemental/http/http_conn.c
+++ b/src/supplemental/http/http_conn.c
@@ -690,8 +690,8 @@ nni_http_conn_fini(nni_http_conn *conn)
}
nni_mtx_unlock(&conn->mtx);
- nni_aio_fini(conn->wr_aio);
- nni_aio_fini(conn->rd_aio);
+ nni_aio_free(conn->wr_aio);
+ nni_aio_free(conn->rd_aio);
nni_free(conn->rd_buf, conn->rd_bufsz);
nni_mtx_fini(&conn->mtx);
NNI_FREE_STRUCT(conn);
@@ -716,8 +716,8 @@ http_init(nni_http_conn **connp, nng_stream *data)
}
conn->rd_bufsz = HTTP_BUFSIZE;
- if (((rv = nni_aio_init(&conn->wr_aio, http_wr_cb, conn)) != 0) ||
- ((rv = nni_aio_init(&conn->rd_aio, http_rd_cb, conn)) != 0)) {
+ if (((rv = nni_aio_alloc(&conn->wr_aio, http_wr_cb, conn)) != 0) ||
+ ((rv = nni_aio_alloc(&conn->rd_aio, http_rd_cb, conn)) != 0)) {
nni_http_conn_fini(conn);
return (rv);
}