summaryrefslogtreecommitdiffstats
path: root/vendor/rustix/src/io
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/rustix/src/io')
-rw-r--r--vendor/rustix/src/io/dup.rs1
-rw-r--r--vendor/rustix/src/io/fcntl.rs12
-rw-r--r--vendor/rustix/src/io/ioctl.rs18
-rw-r--r--vendor/rustix/src/io/read_write.rs6
4 files changed, 16 insertions, 21 deletions
diff --git a/vendor/rustix/src/io/dup.rs b/vendor/rustix/src/io/dup.rs
index 9f5186192..46fb38ad3 100644
--- a/vendor/rustix/src/io/dup.rs
+++ b/vendor/rustix/src/io/dup.rs
@@ -115,6 +115,7 @@ pub fn dup2<Fd: AsFd>(fd: Fd, new: &mut OwnedFd) -> io::Result<()> {
target_os = "aix",
target_os = "espidf",
target_os = "nto",
+ target_os = "vita",
target_os = "wasi"
)))]
#[inline]
diff --git a/vendor/rustix/src/io/fcntl.rs b/vendor/rustix/src/io/fcntl.rs
index 913e9d062..1880ac7db 100644
--- a/vendor/rustix/src/io/fcntl.rs
+++ b/vendor/rustix/src/io/fcntl.rs
@@ -1,10 +1,10 @@
-//! The Unix `fcntl` function is effectively lots of different functions
-//! hidden behind a single dynamic dispatch interface. In order to provide
-//! a type-safe API, rustix makes them all separate functions so that they
-//! can have dedicated static type signatures.
+//! The Unix `fcntl` function is effectively lots of different functions hidden
+//! behind a single dynamic dispatch interface. In order to provide a type-safe
+//! API, rustix makes them all separate functions so that they can have
+//! dedicated static type signatures.
//!
-//! `fcntl` functions which are not specific to files or directories live
-//! in the [`io`] module instead.
+//! `fcntl` functions which are not specific to files or directories live in
+//! the [`io`] module instead.
//!
//! [`io`]: crate::io
diff --git a/vendor/rustix/src/io/ioctl.rs b/vendor/rustix/src/io/ioctl.rs
index e85719a4d..f89160bf3 100644
--- a/vendor/rustix/src/io/ioctl.rs
+++ b/vendor/rustix/src/io/ioctl.rs
@@ -14,16 +14,8 @@ use backend::fd::AsFd;
/// `ioctl(fd, FIOCLEX, NULL)`—Set the close-on-exec flag.
///
-/// Also known as `fcntl(fd, F_SETFD, FD_CLOEXEC)`.
-///
-/// # References
-/// - [Winsock2]
-/// - [NetBSD]
-/// - [OpenBSD]
-///
-/// [Winsock2]: https://docs.microsoft.com/en-us/windows/win32/api/winsock2/nf-winsock2-ioctlsocket
-/// [NetBSD]: https://man.netbsd.org/ioctl.2#GENERIC%20IOCTLS
-/// [OpenBSD]: https://man.openbsd.org/ioctl.2#GENERIC_IOCTLS
+/// This is similar to `fcntl(fd, F_SETFD, FD_CLOEXEC)`, except that it avoids
+/// clearing any other flags that might be set.
#[cfg(apple)]
#[inline]
#[doc(alias = "FIOCLEX")]
@@ -58,8 +50,8 @@ pub fn ioctl_fionbio<Fd: AsFd>(fd: Fd, value: bool) -> io::Result<()> {
/// `ioctl(fd, FIONREAD)`—Returns the number of bytes ready to be read.
///
-/// The result of this function gets silently coerced into a C `int`
-/// by the OS, so it may contain a wrapped value.
+/// The result of this function gets silently coerced into a C `int` by the OS,
+/// so it may contain a wrapped value.
///
/// # References
/// - [Linux]
@@ -73,7 +65,7 @@ pub fn ioctl_fionbio<Fd: AsFd>(fd: Fd, value: bool) -> io::Result<()> {
/// [FreeBSD]: https://man.freebsd.org/cgi/man.cgi?query=ioctl&sektion=2#GENERIC%09IOCTLS
/// [NetBSD]: https://man.netbsd.org/ioctl.2#GENERIC%20IOCTLS
/// [OpenBSD]: https://man.openbsd.org/ioctl.2#GENERIC_IOCTLS
-#[cfg(not(target_os = "espidf"))]
+#[cfg(not(any(target_os = "espidf", target_os = "vita")))]
#[inline]
#[doc(alias = "FIONREAD")]
pub fn ioctl_fionread<Fd: AsFd>(fd: Fd) -> io::Result<u64> {
diff --git a/vendor/rustix/src/io/read_write.rs b/vendor/rustix/src/io/read_write.rs
index 91a28bc39..fe454adba 100644
--- a/vendor/rustix/src/io/read_write.rs
+++ b/vendor/rustix/src/io/read_write.rs
@@ -192,7 +192,8 @@ pub fn writev<Fd: AsFd>(fd: Fd, bufs: &[IoSlice<'_>]) -> io::Result<usize> {
target_os = "haiku",
target_os = "nto",
target_os = "redox",
- target_os = "solaris"
+ target_os = "solaris",
+ target_os = "vita"
)))]
#[inline]
pub fn preadv<Fd: AsFd>(fd: Fd, bufs: &mut [IoSliceMut<'_>], offset: u64) -> io::Result<usize> {
@@ -225,7 +226,8 @@ pub fn preadv<Fd: AsFd>(fd: Fd, bufs: &mut [IoSliceMut<'_>], offset: u64) -> io:
target_os = "haiku",
target_os = "nto",
target_os = "redox",
- target_os = "solaris"
+ target_os = "solaris",
+ target_os = "vita"
)))]
#[inline]
pub fn pwritev<Fd: AsFd>(fd: Fd, bufs: &[IoSlice<'_>], offset: u64) -> io::Result<usize> {