about summary refs log tree commit diff
path: root/resolv/res_send.c
diff options
context:
space:
mode:
authorOndřej Bílka <neleai@seznam.cz>2013-10-13 23:03:28 +0200
committerOndřej Bílka <neleai@seznam.cz>2013-10-14 08:17:09 +0200
commitcabba9343c8bd99e4aea66aa1e0ec7d93aa18a7e (patch)
tree43d7ccc69f7ae2656a5c4b38d4e6f61715bcd71e /resolv/res_send.c
parent94bf958a9435b8d8fbf92c15d8cd5d310029a22c (diff)
downloadglibc-cabba9343c8bd99e4aea66aa1e0ec7d93aa18a7e.tar.gz
glibc-cabba9343c8bd99e4aea66aa1e0ec7d93aa18a7e.tar.xz
glibc-cabba9343c8bd99e4aea66aa1e0ec7d93aa18a7e.zip
Correctly copy resolver address. Fixes bug #13028.
Diffstat (limited to 'resolv/res_send.c')
-rw-r--r--resolv/res_send.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/resolv/res_send.c b/resolv/res_send.c
index 5a73696e55..7f2e85f324 100644
--- a/resolv/res_send.c
+++ b/resolv/res_send.c
@@ -441,7 +441,7 @@ __libc_res_nsend(res_state statp, const u_char *buf, int buflen,
 				    malloc(sizeof (struct sockaddr_in6));
 			if (EXT(statp).nsaddrs[n] != NULL) {
 				memset (mempcpy(EXT(statp).nsaddrs[n],
-						&statp->nsaddr_list[n],
+						&statp->nsaddr_list[ns],
 						sizeof (struct sockaddr_in)),
 					'\0',
 					sizeof (struct sockaddr_in6)