glibc/glibc-rh168253-getaddrinfo-malloc-canonname-strdup-2.patch
Florian Weimer 8597553f96 Rebase DNS stub resolver to the glibc 2.26 version
- Support an arbitrary number of search domains (#168253)
- Detect and apply /etc/resolv.conf changes in libresolv (#1374239)
- CVE-2015-5180: DNS stub resolver crash with crafted record type (#1251403)
2017-10-11 14:41:27 +02:00

20 lines
666 B
Diff

commit 363911ce1313a246b7d33f0983a09e7ab2525b3a
Author: Florian Weimer <fweimer@redhat.com>
Date: Sat Jun 3 08:37:13 2017 +0200
getaddrinfo: Eliminate another strdup call
diff --git a/sysdeps/posix/getaddrinfo.c b/sysdeps/posix/getaddrinfo.c
index 0e92221853dd73b1..317413c9ef1559e6 100644
--- a/sysdeps/posix/getaddrinfo.c
+++ b/sysdeps/posix/getaddrinfo.c
@@ -732,7 +732,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
(*pat)->name = NULL;
else if (canonbuf == NULL)
{
- canonbuf = strdup (air->canon);
+ canonbuf = __strdup (air->canon);
if (canonbuf == NULL)
{
result = -EAI_MEMORY;