aboutsummaryrefslogtreecommitdiff
path: root/lib/libc
diff options
context:
space:
mode:
authorHajimu UMEMOTO <ume@FreeBSD.org>2004-06-16 17:11:20 +0000
committerHajimu UMEMOTO <ume@FreeBSD.org>2004-06-16 17:11:20 +0000
commit7527d8b1c650937e48004e2c3cbb105d37c28bec (patch)
treeda141d19a677bf9903f70ef0c54959ed89d3eddc /lib/libc
parent9ae412aae5fe4a11922f1c2204fc30966ffb6c0f (diff)
Notes
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/getaddrinfo.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/libc/net/getaddrinfo.c b/lib/libc/net/getaddrinfo.c
index d03d8e83c22c..ca76c557c355 100644
--- a/lib/libc/net/getaddrinfo.c
+++ b/lib/libc/net/getaddrinfo.c
@@ -1493,7 +1493,6 @@ _dns_getaddrinfo(pai, hostname, res)
{
struct addrinfo *ai;
querybuf *buf, *buf2;
- const char *name;
struct addrinfo sentinel, *cur;
struct res_target q, q2;
@@ -1517,27 +1516,27 @@ _dns_getaddrinfo(pai, hostname, res)
switch (pai->ai_family) {
case AF_UNSPEC:
/* prefer IPv6 */
- q.name = name;
+ q.name = hostname;
q.qclass = C_IN;
q.qtype = T_AAAA;
q.answer = buf->buf;
q.anslen = sizeof(buf->buf);
q.next = &q2;
- q2.name = name;
+ q2.name = hostname;
q2.qclass = C_IN;
q2.qtype = T_A;
q2.answer = buf2->buf;
q2.anslen = sizeof(buf2->buf);
break;
case AF_INET:
- q.name = name;
+ q.name = hostname;
q.qclass = C_IN;
q.qtype = T_A;
q.answer = buf->buf;
q.anslen = sizeof(buf->buf);
break;
case AF_INET6:
- q.name = name;
+ q.name = hostname;
q.qclass = C_IN;
q.qtype = T_AAAA;
q.answer = buf->buf;