summaryrefslogtreecommitdiff
path: root/src/network/gethostbyaddr.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/network/gethostbyaddr.c')
-rw-r--r--src/network/gethostbyaddr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/network/gethostbyaddr.c b/src/network/gethostbyaddr.c
index 598e2241..c3cacaac 100644
--- a/src/network/gethostbyaddr.c
+++ b/src/network/gethostbyaddr.c
@@ -20,5 +20,5 @@ struct hostent *gethostbyaddr(const void *a, socklen_t l, int af)
err = gethostbyaddr_r(a, l, af, h,
(void *)(h+1), size-sizeof *h, &res, &h_errno);
} while (err == ERANGE);
- return err ? 0 : h;
+ return res;
}