|
|
12745e |
diff -rup glibc-2.17-c758a686/resolv/res_init.c glibc-2.17-c758a686/resolv/res_init.c
|
|
|
12745e |
--- glibc-2.17-c758a686/resolv/res_init.c 2012-07-26 15:10:45.655638776 -0600
|
|
|
12745e |
+++ glibc-2.17-c758a686/resolv/res_init.c 2012-07-26 15:11:27.731423002 -0600
|
|
|
29e444 |
@@ -314,9 +314,9 @@ __res_vinit(res_state statp, int preinit
|
|
|
29e444 |
cp++;
|
|
|
29e444 |
if ((*cp != '\0') && (*cp != '\n')
|
|
|
29e444 |
&& __inet_aton(cp, &a)) {
|
|
|
29e444 |
- statp->nsaddr_list[nservall].sin_addr = a;
|
|
|
29e444 |
- statp->nsaddr_list[nservall].sin_family = AF_INET;
|
|
|
29e444 |
- statp->nsaddr_list[nservall].sin_port =
|
|
|
29e444 |
+ statp->nsaddr_list[nserv].sin_addr = a;
|
|
|
29e444 |
+ statp->nsaddr_list[nserv].sin_family = AF_INET;
|
|
|
29e444 |
+ statp->nsaddr_list[nserv].sin_port =
|
|
|
29e444 |
htons(NAMESERVER_PORT);
|
|
|
29e444 |
nserv++;
|
|
|
29e444 |
#ifdef _LIBC
|
|
|
12745e |
diff -rup glibc-2.17-c758a686/resolv/res_send.c glibc-2.17-c758a686/resolv/res_send.c
|
|
|
12745e |
--- glibc-2.17-c758a686/resolv/res_send.c 2010-05-04 05:27:23.000000000 -0600
|
|
|
12745e |
+++ glibc-2.17-c758a686/resolv/res_send.c 2012-07-26 15:34:58.398261659 -0600
|
|
|
29e444 |
@@ -421,10 +421,10 @@ __libc_res_nsend(res_state statp, const
|
|
|
29e444 |
EXT(statp).nsmap[n] = MAXNS;
|
|
|
29e444 |
}
|
|
|
29e444 |
}
|
|
|
29e444 |
- n = statp->nscount;
|
|
|
29e444 |
- if (statp->nscount > EXT(statp).nscount)
|
|
|
29e444 |
+ n = statp->nscount - EXT(statp).nscount6;
|
|
|
29e444 |
+ if (n > EXT(statp).nscount)
|
|
|
29e444 |
for (n = EXT(statp).nscount, ns = 0;
|
|
|
29e444 |
- n < statp->nscount; n++) {
|
|
|
29e444 |
+ n < statp->nscount - EXT(statp).nscount6; n++) {
|
|
|
29e444 |
while (ns < MAXNS
|
|
|
29e444 |
&& EXT(statp).nsmap[ns] != MAXNS)
|
|
|
29e444 |
ns++;
|
|
|
29e444 |
@@ -441,7 +441,7 @@ __libc_res_nsend(res_state statp, const
|
|
|
29e444 |
malloc(sizeof (struct sockaddr_in6));
|
|
|
29e444 |
if (EXT(statp).nsaddrs[n] != NULL) {
|
|
|
29e444 |
memset (mempcpy(EXT(statp).nsaddrs[n],
|
|
|
29e444 |
- &statp->nsaddr_list[n],
|
|
|
29e444 |
+ &statp->nsaddr_list[ns],
|
|
|
29e444 |
sizeof (struct sockaddr_in)),
|
|
|
29e444 |
'\0',
|
|
|
29e444 |
sizeof (struct sockaddr_in6)
|