summaryrefslogtreecommitdiff
path: root/src/unix/haiku
diff options
context:
space:
mode:
authorNiels Sascha Reedijk <niels.reedijk@gmail.com>2021-03-11 22:15:44 +0000
committerNiels Sascha Reedijk <niels.reedijk@gmail.com>2021-03-12 11:10:52 +0000
commitd4e4814f320a838b2a1a13ba6e2009b274e3f784 (patch)
tree088a72d7cb5fb8665beeb06a3674dcee34f42c73 /src/unix/haiku
parent0687d245f736316959ccc3edb11683035ca49d3b (diff)
downloadrust-libc-d4e4814f320a838b2a1a13ba6e2009b274e3f784.tar.gz
Haiku: change argument types for readv() and writev()
This crate's definition was recently updated to conform to the actual type definition in the header files. However, this deviates from the standard, and thus breaks building - amongst others - libstd. This reverts to the original definition. Parallel to this, there is an effort to fix the definition on Haiku. In the interim, the disparity between the definitions should not cause any issues for users that pass valid vector sizes.
Diffstat (limited to 'src/unix/haiku')
-rw-r--r--src/unix/haiku/mod.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/unix/haiku/mod.rs b/src/unix/haiku/mod.rs
index f830977ea4..0fc9024ec6 100644
--- a/src/unix/haiku/mod.rs
+++ b/src/unix/haiku/mod.rs
@@ -874,6 +874,7 @@ pub const LOCK_UN: ::c_int = 0x08;
pub const SIGSTKSZ: ::size_t = 16384;
+pub const IOV_MAX: ::c_int = 1024;
pub const PATH_MAX: ::c_int = 1024;
pub const SA_NOCLDSTOP: ::c_int = 0x01;
@@ -1502,12 +1503,12 @@ extern "C" {
pub fn writev(
fd: ::c_int,
iov: *const ::iovec,
- count: ::size_t,
+ count: ::c_int,
) -> ::ssize_t;
pub fn readv(
fd: ::c_int,
iov: *const ::iovec,
- count: ::size_t,
+ count: ::c_int,
) -> ::ssize_t;
pub fn sendmsg(