Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 4 additions & 12 deletions library/std/src/sys/fd/unix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,9 @@
#[cfg(test)]
mod tests;

#[cfg(not(any(
target_os = "linux",
target_os = "l4re",
target_os = "android",
target_os = "hurd",
)))]
#[cfg(not(any(target_os = "linux", target_os = "android", target_os = "hurd")))]
use libc::off_t as off64_t;
#[cfg(any(
target_os = "android",
target_os = "linux",
target_os = "l4re",
target_os = "hurd",
))]
#[cfg(any(target_os = "android", target_os = "linux", target_os = "hurd"))]
use libc::off64_t;

cfg_select! {
Expand Down Expand Up @@ -246,6 +236,7 @@ impl FileDesc {
target_os = "linux",
target_os = "netbsd",
target_os = "openbsd", // OpenBSD 2.7
target_os = "l4re",
all(target_os = "macos", target_arch = "aarch64"),
))]
pub fn read_vectored_at(&self, bufs: &mut [IoSliceMut<'_>], offset: u64) -> io::Result<usize> {
Expand Down Expand Up @@ -273,6 +264,7 @@ impl FileDesc {
target_os = "netbsd",
target_os = "openbsd",
target_vendor = "apple",
target_os = "l4re",
)))]
pub fn read_vectored_at(&self, bufs: &mut [IoSliceMut<'_>], offset: u64) -> io::Result<usize> {
io::default_read_vectored(|b| self.read_at(b, offset), bufs)
Expand Down
1 change: 0 additions & 1 deletion library/std/src/sys/fs/unix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1086,7 +1086,6 @@ impl DirEntry {
target_os = "nto",
target_os = "qnx",
target_os = "vita",
target_os = "l4re",
)))]
match self.entry.d_type {
libc::DT_CHR => return Ok(FileType { mode: libc::S_IFCHR }),
Expand Down
2 changes: 2 additions & 0 deletions library/std/src/sys/pal/unix/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ pub unsafe fn init(argc: isize, argv: *const *const u8, sigpipe: u8) {
target_os = "horizon",
target_os = "vxworks",
target_os = "vita",
target_os = "l4re",
)))]
static ON_BROKEN_PIPE_USED: crate::sync::atomic::Atomic<bool> =
crate::sync::atomic::AtomicBool::new(false);
Expand All @@ -205,6 +206,7 @@ static ON_BROKEN_PIPE_USED: crate::sync::atomic::Atomic<bool> =
target_os = "vxworks",
target_os = "vita",
target_os = "nuttx",
target_os = "l4re",
)))]
pub(crate) fn on_broken_pipe_used() -> bool {
ON_BROKEN_PIPE_USED.load(crate::sync::atomic::Ordering::Relaxed)
Expand Down
Loading