Skip to content

Commit 54c7267

Browse files
committed
musl: mips64: Fix type of nlink_t
musl defines nlink_t to be an unsigned 32-bit integer on mips64, therefore changing the size of stat64 from 216 bytes to 208. The current definition in the libc crate does not match this and therefore defines stat64 wrong on mips64 musl, which results in bogus readings of fields following st_nlink. See https://git.musl-libc.org/cgit/musl/tree/arch/mips64/bits/alltypes.h.in#n22 for the musl definition of nlink_t. Signed-off-by: Jens Reidel <[email protected]>
1 parent 9ba4f41 commit 54c7267

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/unix/linux_like/linux/musl/b64/mips64.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use crate::prelude::*;
44
pub type wchar_t = i32;
55
pub type __u64 = c_ulong;
66
pub type __s64 = c_long;
7-
pub type nlink_t = u64;
7+
pub type nlink_t = c_uint;
88
pub type blksize_t = i64;
99

1010
s! {

0 commit comments

Comments
 (0)