sunfishcode / c-ward

An implementation of libc written in Rust
Other
187 stars 11 forks source link

Remove `READ_BUFFER`. #133

Closed sunfishcode closed 3 months ago

sunfishcode commented 3 months ago

READ_BUFFER was originally added for read, but read no longer needs it now that we can use rustix::io::read_uninit. So the only thing left using READ_BUFFER is the xattr functions. It wasn't really correct for the xattr functions to use a PIPE_BUF-sized buffer anyway, so remove READ_BUFFER entirely and just use Vecs for their buffers.

This also fixes compile errors with u8/i8 mismatches when linux-raw-sys/std is enabled.

Fixes #132.