mirror of
git://sourceware.org/git/glibc.git
synced 2025-01-18 12:16:13 +08:00
nss_dns: Fix assertion failure in _nss_dns_getcanonname_r [BZ #19865]
This commit is contained in:
parent
eb68636fed
commit
d29fb41f44
@ -1,3 +1,9 @@
|
|||||||
|
2016-04-11 Florian Weimer <fweimer@redhat.com>
|
||||||
|
|
||||||
|
[BZ #19865]
|
||||||
|
* resolv/nss_dns/dns-canon.c (_nss_dns_getcanonname_r): Restore
|
||||||
|
original buffer before retry.
|
||||||
|
|
||||||
2016-04-10 Samuel Thibault <samuel.thibault@ens-lyon.org>
|
2016-04-10 Samuel Thibault <samuel.thibault@ens-lyon.org>
|
||||||
|
|
||||||
* sysdeps/generic/ldsodefs.h (struct rtld_global_ro)
|
* sysdeps/generic/ldsodefs.h (struct rtld_global_ro)
|
||||||
|
@ -144,6 +144,13 @@ _nss_dns_getcanonname_r (const char *name, char *buffer, size_t buflen,
|
|||||||
ptr += sizeof (uint16_t) + __ns_get16 (ptr);
|
ptr += sizeof (uint16_t) + __ns_get16 (ptr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Restore original buffer before retry. */
|
||||||
|
if (ansp.ptr != buf)
|
||||||
|
{
|
||||||
|
free (ansp.ptr);
|
||||||
|
ansp.ptr = buf;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
out:
|
out:
|
||||||
|
Loading…
Reference in New Issue
Block a user