mirror of
https://codeberg.org/ziglang/zig.git
synced 2026-03-08 02:44:43 +01:00
std: make all dirent structs extern
Using structs with unspecified layout on the ABI boundry can't end well.
This commit is contained in:
parent
254a3ba9d9
commit
687a756bf9
2 changed files with 3 additions and 3 deletions
|
|
@ -171,7 +171,7 @@ pub const RTLD = struct {
|
|||
pub const LOCAL = 0;
|
||||
};
|
||||
|
||||
pub const dirent = struct {
|
||||
pub const dirent = extern struct {
|
||||
ino: c_uint,
|
||||
off: c_uint,
|
||||
reclen: c_ushort,
|
||||
|
|
|
|||
|
|
@ -330,14 +330,14 @@ pub const RTLD = struct {
|
|||
pub const LOCAL = 0;
|
||||
};
|
||||
|
||||
pub const dirent = struct {
|
||||
pub const dirent = extern struct {
|
||||
ino: c_uint,
|
||||
off: c_uint,
|
||||
reclen: c_ushort,
|
||||
type: u8,
|
||||
name: [256]u8,
|
||||
};
|
||||
pub const dirent64 = struct {
|
||||
pub const dirent64 = extern struct {
|
||||
ino: c_ulong,
|
||||
off: c_ulong,
|
||||
reclen: c_ushort,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue