motiejus/zig

fork of https://codeberg.org/ziglang/zig
git clone https://git.jakstys.lt/motiejus/zig.git
Log | Tree | Refs | README | LICENSE

commit a05ae01b4fba950fa0bddb8e33ed757b592d9b47 (tree)
parent 1344706b4771dbd2b3d477f354f3f5e5e20b416e
Author: Isaac Freund <ifreund@ifreund.xyz>
Date:   Thu, 19 Nov 2020 19:16:54 +0100

std/os: define and use dev_t for linux x86_64

Diffstat:
Mlib/std/os/bits/linux/x86_64.zig | 5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/std/os/bits/linux/x86_64.zig b/lib/std/os/bits/linux/x86_64.zig @@ -512,10 +512,11 @@ pub const msghdr_const = extern struct { pub const off_t = i64; pub const ino_t = u64; +pub const dev_t = u64; // The `stat` definition used by the Linux kernel. pub const kernel_stat = extern struct { - dev: u64, + dev: dev_t, ino: ino_t, nlink: usize, @@ -523,7 +524,7 @@ pub const kernel_stat = extern struct { uid: uid_t, gid: gid_t, __pad0: u32, - rdev: u64, + rdev: dev_t, size: off_t, blksize: isize, blocks: i64,