From 7f1f6d96b404be21cd873a8a2eb408ec732c6a39 Mon Sep 17 00:00:00 2001 From: Jelle Raaijmakers Date: Sun, 4 Apr 2021 02:00:03 +0200 Subject: [PATCH] LibC: Add NI_MAXHOST and NI_MAXSERV constants These are not POSIX-defined but are almost always present in . --- Userland/Libraries/LibC/netdb.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Userland/Libraries/LibC/netdb.h b/Userland/Libraries/LibC/netdb.h index 292ba81c24..d60f07217f 100644 --- a/Userland/Libraries/LibC/netdb.h +++ b/Userland/Libraries/LibC/netdb.h @@ -106,6 +106,9 @@ struct addrinfo { #define AI_ALL 0x0020 #define AI_ADDRCONFIG 0x0040 +#define NI_MAXHOST 1025 +#define NI_MAXSERV 32 + int getaddrinfo(const char* __restrict node, const char* __restrict service, const struct addrinfo* __restrict hints, struct addrinfo** __restrict res); void freeaddrinfo(struct addrinfo* res); const char* gai_strerror(int errcode);