mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 14:23:09 +00:00
std.c: Use std.c.NI as the flags type in getnameinfo
std.c.NI was never used in the source, so let's finally use it and make
the function more clear!
This is a breaking change, although a minor one: If you previously passed 0 here
(meaning no flags), then now you have to pass an empty struct (.{}) instead.
Otherwise, you probably used @bitCast() shenanigans here (like
@bitCast(c.NI { .NUMERICHOST = true }) and that will still work, but you can
also get rid of the @bitCast() now!
This commit is contained in:
parent
18ffd48b60
commit
2ccfb1dafd
@ -9774,7 +9774,7 @@ pub extern "c" fn getnameinfo(
|
||||
hostlen: socklen_t,
|
||||
noalias serv: ?[*]u8,
|
||||
servlen: socklen_t,
|
||||
flags: u32,
|
||||
flags: NI,
|
||||
) EAI;
|
||||
|
||||
pub extern "c" fn gai_strerror(errcode: EAI) [*:0]const u8;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user