]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/glibc/glibc-rh1209376.patch
dhcpcd: fix delay after dhcp down.
[ipfire-2.x.git] / src / patches / glibc / glibc-rh1209376.patch
CommitLineData
30ca037f
MT
1@@ -, +, @@
2 resolv/nss_dns/dns-host.c:getanswer_r.
3---
4 resolv/nss_dns/dns-host.c | 3 ++-
5 1 file changed, 2 insertions(+), 1 deletion(-)
6--- a/resolv/nss_dns/dns-host.c
7+++ a/resolv/nss_dns/dns-host.c
8@@ -615,7 +615,8 @@ getanswer_r (const querybuf *answer, int anslen, const char *qname, int qtype,
9 int have_to_map = 0;
10 uintptr_t pad = -(uintptr_t) buffer % __alignof__ (struct host_data);
11 buffer += pad;
12- if (__builtin_expect (buflen < sizeof (struct host_data) + pad, 0))
13+ buflen = buflen > pad ? buflen - pad : 0;
14+ if (__builtin_expect (buflen < sizeof (struct host_data), 0))
15 {
16 /* The buffer is too small. */
17 too_small:
18--