mirror of
https://github.com/ziglang/zig.git
synced 2026-02-21 16:54:52 +00:00
std.net: fix reference to incorrect constant name
This commit is contained in:
parent
61d5a0bf48
commit
788848e123
@ -1271,7 +1271,7 @@ pub const TcpServer = struct {
|
||||
pub fn listen(self: *TcpServer, address: IpAddress) !void {
|
||||
const nonblock = if (std.io.is_async) os.SOCK_NONBLOCK else 0;
|
||||
const sock_flags = os.SOCK_STREAM | os.SOCK_CLOEXEC | nonblock;
|
||||
const sockfd = try os.socket(os.AF_INET, sock_flags, os.PROTO_tcp);
|
||||
const sockfd = try os.socket(os.AF_INET, sock_flags, os.IPPROTO_TCP);
|
||||
self.sockfd = sockfd;
|
||||
errdefer {
|
||||
os.close(sockfd);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user