diff options
-rw-r--r-- | src/core/network.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core/network.c b/src/core/network.c index 28189661..8abc1ba1 100644 --- a/src/core/network.c +++ b/src/core/network.c @@ -447,8 +447,10 @@ int net_gethostbyaddr(IPADDR *ip, char **name) sin_set_ip(&so, ip); /* save error to host_error for later use */ - host_error = getnameinfo((struct sockaddr *) &so, sizeof(so), - hostname, sizeof(hostname), NULL, 0, 0); + host_error = getnameinfo((struct sockaddr *)&so, sizeof(so), + hostname, sizeof(hostname), + NULL, 0, + NI_NAMEREQD); if (host_error != 0) return host_error; |