mirror of
https://sourceware.org/git/glibc.git
synced 2024-12-23 03:10:05 +00:00
* sysdeps/posix/getaddrinfo.c (gaih_inet): After gethostbyname4_r
lookup, don't assign canon unconditionally.
This commit is contained in:
parent
0caca71ac9
commit
91c8a74b8b
@ -1,3 +1,8 @@
|
|||||||
|
2008-05-16 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
|
* sysdeps/posix/getaddrinfo.c (gaih_inet): After gethostbyname4_r
|
||||||
|
lookup, don't assign canon unconditionally.
|
||||||
|
|
||||||
2008-05-14 Ulrich Drepper <drepper@redhat.com>
|
2008-05-14 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
* string/Makefile (distribute): Add str-two-way.h.
|
* string/Makefile (distribute): Add str-two-way.h.
|
||||||
|
@ -729,6 +729,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
|
|||||||
|
|
||||||
if (status == NSS_STATUS_SUCCESS)
|
if (status == NSS_STATUS_SUCCESS)
|
||||||
{
|
{
|
||||||
|
if ((req->ai_flags & AI_CANONNAME) != 0 && canon == NULL)
|
||||||
canon = (*pat)->name;
|
canon = (*pat)->name;
|
||||||
|
|
||||||
while (*pat != NULL)
|
while (*pat != NULL)
|
||||||
@ -953,7 +954,7 @@ gaih_inet (const char *name, const struct gaih_service *service,
|
|||||||
return -EAI_IDN_ENCODE;
|
return -EAI_IDN_ENCODE;
|
||||||
}
|
}
|
||||||
/* In case the output string is the same as the input
|
/* In case the output string is the same as the input
|
||||||
string no new string has been allocated. Otherwise
|
string no new string has been allocated and we
|
||||||
make a copy. */
|
make a copy. */
|
||||||
if (out == canon)
|
if (out == canon)
|
||||||
goto make_copy;
|
goto make_copy;
|
||||||
|
Loading…
Reference in New Issue
Block a user