diff options
author | Jens Axboe <axboe@kernel.dk> | 2019-01-17 21:33:39 -0700 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2019-01-17 21:33:39 -0700 |
commit | 257578052a4dacd891e96e90b7fe775bb73325a5 (patch) | |
tree | af9be0dee1e38d07c6c441dbc682a8a0c3f7f1f7 /src | |
parent | b7e86eb7db6449180e13df9ff42e0c51f0d55bc4 (diff) |
liburing: ensure prep helpers actually set iovec count
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'src')
-rw-r--r-- | src/liburing.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/liburing.h b/src/liburing.h index 4a8c55f..8e5e2ee 100644 --- a/src/liburing.h +++ b/src/liburing.h @@ -79,7 +79,7 @@ static inline void io_uring_prep_readv(struct io_uring_sqe *sqe, int fd, sqe->fd = fd; sqe->off = offset; sqe->addr = (unsigned long) iovecs; - sqe->len = 1; + sqe->len = nr_vecs; } static inline void io_uring_prep_writev(struct io_uring_sqe *sqe, int fd, @@ -91,7 +91,7 @@ static inline void io_uring_prep_writev(struct io_uring_sqe *sqe, int fd, sqe->fd = fd; sqe->off = offset; sqe->addr = (unsigned long) iovecs; - sqe->len = 1; + sqe->len = nr_vecs; } static inline void io_uring_prep_poll(struct io_uring_sqe *sqe, int fd, |