diff options
Diffstat (limited to 'src/network')
-rw-r--r-- | src/network/getaddrinfo.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/network/getaddrinfo.c b/src/network/getaddrinfo.c index c88d558c..b9439f77 100644 --- a/src/network/getaddrinfo.c +++ b/src/network/getaddrinfo.c @@ -20,6 +20,8 @@ int getaddrinfo(const char *restrict host, const char *restrict serv, const stru } sa; } *out; + if (!host && !serv) return EAI_NONAME; + if (hint) { family = hint->ai_family; flags = hint->ai_flags; |