diff options
Diffstat (limited to 'networking/nslookup.c')
-rw-r--r-- | networking/nslookup.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/networking/nslookup.c b/networking/nslookup.c index 608e65462..0036d0d17 100644 --- a/networking/nslookup.c +++ b/networking/nslookup.c | |||
@@ -72,8 +72,8 @@ static int print_host(const char *hostname, const char *header) | |||
72 | // printf("%s\n", cur->ai_canonname); ? | 72 | // printf("%s\n", cur->ai_canonname); ? |
73 | while (cur) { | 73 | while (cur) { |
74 | char *dotted, *revhost; | 74 | char *dotted, *revhost; |
75 | dotted = xmalloc_sockaddr2dotted_noport(cur->ai_addr, cur->ai_addrlen); | 75 | dotted = xmalloc_sockaddr2dotted_noport(cur->ai_addr); |
76 | revhost = xmalloc_sockaddr2hostonly_noport(cur->ai_addr, cur->ai_addrlen); | 76 | revhost = xmalloc_sockaddr2hostonly_noport(cur->ai_addr); |
77 | 77 | ||
78 | printf("Address %u: %s%c", ++cnt, dotted, revhost ? ' ' : '\n'); | 78 | printf("Address %u: %s%c", ++cnt, dotted, revhost ? ' ' : '\n'); |
79 | if (revhost) { | 79 | if (revhost) { |
@@ -102,8 +102,7 @@ static void server_print(void) | |||
102 | { | 102 | { |
103 | char *server; | 103 | char *server; |
104 | 104 | ||
105 | server = xmalloc_sockaddr2dotted_noport((struct sockaddr*)&_res.nsaddr_list[0], | 105 | server = xmalloc_sockaddr2dotted_noport((struct sockaddr*)&_res.nsaddr_list[0]); |
106 | sizeof(struct sockaddr_in)); | ||
107 | /* I honestly don't know what to do if DNS server has _IPv6 address_. | 106 | /* I honestly don't know what to do if DNS server has _IPv6 address_. |
108 | * Probably it is listed in | 107 | * Probably it is listed in |
109 | * _res._u._ext_.nsaddrs[MAXNS] (of type "struct sockaddr_in6*" each) | 108 | * _res._u._ext_.nsaddrs[MAXNS] (of type "struct sockaddr_in6*" each) |