Skip to content

Commit

Permalink
fixup! Adapt sparc statfs and statvfs for gnu_time_bits64
Browse files Browse the repository at this point in the history
  • Loading branch information
snogge committed Feb 11, 2025
1 parent 9482c40 commit 1138127
Showing 1 changed file with 36 additions and 36 deletions.
72 changes: 36 additions & 36 deletions src/unix/linux_like/linux/gnu/b32/sparc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,42 +12,6 @@ cfg_if! {
}
}

cfg_if! {
if #[cfg(not(gnu_file_offset_bits64))] {
s! {
pub struct statfs64 {
pub f_type: crate::__fsword_t,
pub f_bsize: crate::__fsword_t,
pub f_blocks: u64,
pub f_bfree: u64,
pub f_bavail: u64,
pub f_files: u64,
pub f_ffree: u64,
pub f_fsid: crate::fsid_t,
pub f_namelen: crate::__fsword_t,
pub f_frsize: crate::__fsword_t,
pub f_flags: crate::__fsword_t,
pub f_spare: [crate::__fsword_t; 4],
}

pub struct statvfs64 {
pub f_bsize: c_ulong,
pub f_frsize: c_ulong,
pub f_blocks: u64,
pub f_bfree: u64,
pub f_bavail: u64,
pub f_files: u64,
pub f_ffree: u64,
pub f_favail: u64,
pub f_fsid: c_ulong,
pub f_flag: c_ulong,
pub f_namemax: c_ulong,
__f_spare: [c_int; 6],
}
}
}
}

s! {
pub struct sigaction {
pub sa_sigaction: crate::sighandler_t,
Expand Down Expand Up @@ -172,6 +136,42 @@ s! {
}
}

cfg_if! {
if #[cfg(not(gnu_file_offset_bits64))] {
s! {
pub struct statfs64 {
pub f_type: crate::__fsword_t,
pub f_bsize: crate::__fsword_t,
pub f_blocks: u64,
pub f_bfree: u64,
pub f_bavail: u64,
pub f_files: u64,
pub f_ffree: u64,
pub f_fsid: crate::fsid_t,
pub f_namelen: crate::__fsword_t,
pub f_frsize: crate::__fsword_t,
pub f_flags: crate::__fsword_t,
pub f_spare: [crate::__fsword_t; 4],
}

pub struct statvfs64 {
pub f_bsize: c_ulong,
pub f_frsize: c_ulong,
pub f_blocks: u64,
pub f_bfree: u64,
pub f_bavail: u64,
pub f_files: u64,
pub f_ffree: u64,
pub f_favail: u64,
pub f_fsid: c_ulong,
pub f_flag: c_ulong,
pub f_namemax: c_ulong,
__f_spare: [c_int; 6],
}
}
}
}

s_no_extra_traits! {
#[allow(missing_debug_implementations)]
#[repr(align(8))]
Expand Down

0 comments on commit 1138127

Please sign in to comment.