]> git.ipfire.org Git - ipfire-2.x.git/blob - src/patches/glibc/glibc-rh656014.patch
lcdproc: Update to 0.5.7
[ipfire-2.x.git] / src / patches / glibc / glibc-rh656014.patch
1 2010-11-24 Andreas Schwab <schwab@redhat.com>
2
3 * resolv/nss_dns/dns-host.c (getanswer_r): Don't handle ttl == 0
4 specially.
5 (gaih_getanswer_slice): Likewise.
6
7 Index: glibc-2.12-2-gc4ccff1/resolv/nss_dns/dns-host.c
8 ===================================================================
9 --- glibc-2.12-2-gc4ccff1.orig/resolv/nss_dns/dns-host.c
10 +++ glibc-2.12-2-gc4ccff1/resolv/nss_dns/dns-host.c
11 @@ -599,7 +599,6 @@ getanswer_r (const querybuf *answer, int
12 int (*name_ok) (const char *);
13 u_char packtmp[NS_MAXCDNAME];
14 int have_to_map = 0;
15 - int32_t ttl = 0;
16 uintptr_t pad = -(uintptr_t) buffer % __alignof__ (struct host_data);
17 buffer += pad;
18 if (__builtin_expect (buflen < sizeof (struct host_data) + pad, 0))
19 @@ -733,7 +732,7 @@ getanswer_r (const querybuf *answer, int
20 cp += INT16SZ; /* type */
21 class = __ns_get16 (cp);
22 cp += INT16SZ; /* class */
23 - ttl = __ns_get32 (cp);
24 + int32_t ttl = __ns_get32 (cp);
25 cp += INT32SZ; /* TTL */
26 n = __ns_get16 (cp);
27 cp += INT16SZ; /* len */
28 @@ -907,7 +906,7 @@ getanswer_r (const querybuf *answer, int
29 {
30 register int nn;
31
32 - if (ttlp != NULL && ttl != 0)
33 + if (ttlp != NULL)
34 *ttlp = ttl;
35 if (canonp != NULL)
36 *canonp = bp;
37 @@ -1163,7 +1162,7 @@ gaih_getanswer_slice (const querybuf *an
38
39 if (*firstp)
40 {
41 - if (ttl != 0 && ttlp != NULL)
42 + if (ttlp != NULL)
43 *ttlp = ttl;
44
45 (*pat)->name = canon ?: h_name;