diff options
Diffstat (limited to 'sysdeps/posix/getaddrinfo.c')
-rw-r--r-- | sysdeps/posix/getaddrinfo.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/posix/getaddrinfo.c b/sysdeps/posix/getaddrinfo.c index f43aa03d1f..6810963357 100644 --- a/sysdeps/posix/getaddrinfo.c +++ b/sysdeps/posix/getaddrinfo.c @@ -206,7 +206,7 @@ gaih_inet_serv (const char *servicename, struct gaih_typeproto *tp, r = __getservbyname_r (servicename, tp->name, &ts, tmpbuf, tmpbuflen, &s); - if (r) + if (r || s == NULL) { if (errno == ERANGE) tmpbuflen *= 2; |