diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2023-07-12 16:53:59 +0000 |
---|---|---|
committer | Laurent Bercot <ska@appnovation.com> | 2023-07-12 16:53:59 +0000 |
commit | 207845f50a8fb54fe8e584928078dc3687399caf (patch) | |
tree | f58eac67edc2dbaba13a48442a2093f76e869991 /src/clients/s6-dnsq.c | |
parent | 8cf671e973a4ea2ef7c9ca1321531a7ceeaa5073 (diff) | |
download | s6-dns-207845f50a8fb54fe8e584928078dc3687399caf.tar.xz |
Pass on all clients, add hosts support wherever applicable
Signed-off-by: Laurent Bercot <ska@appnovation.com>
Diffstat (limited to 'src/clients/s6-dnsq.c')
-rw-r--r-- | src/clients/s6-dnsq.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/clients/s6-dnsq.c b/src/clients/s6-dnsq.c index c6d50cf..6f85c42 100644 --- a/src/clients/s6-dnsq.c +++ b/src/clients/s6-dnsq.c @@ -3,6 +3,7 @@ #include <string.h> #include <stdint.h> #include <errno.h> + #include <skalibs/types.h> #include <skalibs/bitarray.h> #include <skalibs/strerr.h> @@ -11,6 +12,7 @@ #include <skalibs/genwrite.h> #include <skalibs/tai.h> #include <skalibs/ip46.h> + #include <s6-dns/s6dns.h> #include <s6-dns/s6dns-analyze.h> #include <s6-dns/s6dns-debug.h> @@ -60,11 +62,10 @@ int main (int argc, char const *const *argv) { ip46 z[S6DNS_MAX_SERVERS] ; size_t n ; - unsigned int k = 0 ; if (!*argv[2+i]) continue ; if (!ip46_scanlist(z, S6DNS_MAX_SERVERS - j, argv[2 + i], &n)) strerr_diefu2sys(100, "make an IP address list out of ", argv[2+i]) ; - for (; k < n ; k++) + for (size_t k = 0 ; k < n ; k++) { memcpy(s6dns_ip46list_ip(&servers, j + k), z[k].ip, SKALIBS_IP_SIZE) ; #ifdef SKALIBS_IPV6_ENABLED |