aboutgitcodebugslistschat
path: root/iov.h
diff options
context:
space:
mode:
Diffstat (limited to 'iov.h')
-rw-r--r--iov.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/iov.h b/iov.h
index 6058af7..5668ca5 100644
--- a/iov.h
+++ b/iov.h
@@ -18,6 +18,9 @@
#include <unistd.h>
#include <string.h>
+#define IOV_OF_LVALUE(lval) \
+ (struct iovec){ .iov_base = &(lval), .iov_len = sizeof(lval) }
+
size_t iov_skip_bytes(const struct iovec *iov, size_t n,
size_t skip, size_t *offset);
size_t iov_from_buf(const struct iovec *iov, size_t iov_cnt,