From 5914e40c2ff7fcf346c90705785f3fb7650a9fdc Mon Sep 17 00:00:00 2001 From: Garrett D'Amore Date: Mon, 29 Jan 2018 13:27:52 -0800 Subject: Expose scatter/gather I/O vectors; we will use for HTTP API. --- src/supplemental/http/http.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/supplemental') diff --git a/src/supplemental/http/http.c b/src/supplemental/http/http.c index 43db1d15..2ba5b274 100644 --- a/src/supplemental/http/http.c +++ b/src/supplemental/http/http.c @@ -145,7 +145,7 @@ http_rd_buf(nni_http *http, nni_aio *aio) } memcpy(aio->a_iov[0].iov_buf, rbuf, n); aio->a_iov[0].iov_len -= n; - aio->a_iov[0].iov_buf += n; + NNI_INCPTR(aio->a_iov[0].iov_buf, n); http->rd_get += n; rbuf += n; aio->a_count += n; @@ -302,7 +302,7 @@ http_rd_cb(void *arg) n = cnt; } uaio->a_iov[0].iov_len -= n; - uaio->a_iov[0].iov_buf += n; + NNI_INCPTR(uaio->a_iov[0].iov_buf, n); uaio->a_count += n; cnt -= n; @@ -420,7 +420,7 @@ http_wr_cb(void *arg) if (aio->a_iov[0].iov_len > n) { aio->a_iov[0].iov_len -= n; - aio->a_iov[0].iov_buf += n; + NNI_INCPTR(aio->a_iov[0].iov_buf, n); break; } n -= aio->a_iov[0].iov_len; -- cgit v1.2.3-70-g09d2