summaryrefslogtreecommitdiff
path: root/cross/cross-mips64el-unknown-linux-gnu-glibc-headers/glibc-2.14-revert-4768ae77.patch
blob: 11f087cb761eb2ff059600bbbacd66f36666827a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
diff -Naur glibc-orig//resolv/res_send.c glibc/resolv/res_send.c
--- glibc-orig//resolv/res_send.c	2011-06-10 18:59:03.041436996 +1000
+++ glibc/resolv/res_send.c	2011-06-10 19:08:09.379309323 +1000
@@ -549,7 +549,7 @@
 				    ns, ansp, ansp2, nansp2, resplen2);
 			if (n < 0)
 				return (-1);
-			if (n == 0 && (buf2 == NULL || *resplen2 == 0))
+			if (n == 0)
 				goto next_ns;
 		} else {
 			/* Use datagrams. */
@@ -559,7 +559,7 @@
 				    ansp2, nansp2, resplen2);
 			if (n < 0)
 				return (-1);
-			if (n == 0 && (buf2 == NULL || *resplen2 == 0))
+			if (n == 0)
 				goto next_ns;
 			if (v_circuit)
 			  // XXX Check whether both requests failed or
@@ -1275,14 +1275,10 @@
 				(*thisresplenp > *thisanssizp)
 				? *thisanssizp : *thisresplenp);
 
-			if (recvresp1 || (buf2 != NULL && recvresp2)) {
-			  *resplen2 = 0;
+			if (recvresp1 || (buf2 != NULL && recvresp2))
 			  return resplen;
-			}
 			if (buf2 != NULL)
 			  {
-			    /* No data from the first reply.  */
-			    resplen = 0;
 			    /* We are waiting for a possible second reply.  */
 			    if (hp->id == anhp->id)
 			      recvresp1 = 1;