summaryrefslogtreecommitdiffstats
path: root/plugins/check_dns.c
diff options
context:
space:
mode:
authorLorenz Kästle <12514511+RincewindsHat@users.noreply.github.com>2023-11-01 11:05:50 +0100
committerGitHub <noreply@github.com>2023-11-01 11:05:50 +0100
commit6d08e1c8c96d0327a5b819dc1fbb0d5754f3e2e5 (patch)
tree575867b1d1eef4cd20215f22f9151ebb4a02c93d /plugins/check_dns.c
parent03bde80abbda6fba2225568c3285a2ff2b5445a8 (diff)
parent76d9f25cd0dbe99657baeb6fa139a1831558adae (diff)
downloadmonitoring-plugins-6d08e1c.tar.gz
Merge branch 'master' into fix_check_mailq
Diffstat (limited to 'plugins/check_dns.c')
-rw-r--r--plugins/check_dns.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/check_dns.c b/plugins/check_dns.c
index 82dc264a..5e20214c 100644
--- a/plugins/check_dns.c
+++ b/plugins/check_dns.c
@@ -122,7 +122,7 @@ main (int argc, char **argv)
122 } 122 }
123 123
124 /* scan stdout */ 124 /* scan stdout */
125 for(i = 0; i < chld_out.lines; i++) { 125 for(size_t i = 0; i < chld_out.lines; i++) {
126 if (addresses == NULL) 126 if (addresses == NULL)
127 addresses = malloc(sizeof(*addresses)*10); 127 addresses = malloc(sizeof(*addresses)*10);
128 else if (!(n_addresses % 10)) 128 else if (!(n_addresses % 10))
@@ -197,7 +197,7 @@ main (int argc, char **argv)
197 } 197 }
198 198
199 /* scan stderr */ 199 /* scan stderr */
200 for(i = 0; i < chld_err.lines; i++) { 200 for(size_t i = 0; i < chld_err.lines; i++) {
201 if (verbose) 201 if (verbose)
202 puts(chld_err.line[i]); 202 puts(chld_err.line[i]);
203 203
@@ -241,7 +241,7 @@ main (int argc, char **argv)
241 unsigned long expect_match = (1 << expected_address_cnt) - 1; 241 unsigned long expect_match = (1 << expected_address_cnt) - 1;
242 unsigned long addr_match = (1 << n_addresses) - 1; 242 unsigned long addr_match = (1 << n_addresses) - 1;
243 243
244 for (i=0; i<expected_address_cnt; i++) { 244 for (int i=0; i<expected_address_cnt; i++) {
245 int j; 245 int j;
246 /* check if we get a match on 'raw' ip or cidr */ 246 /* check if we get a match on 'raw' ip or cidr */
247 for (j=0; j<n_addresses; j++) { 247 for (j=0; j<n_addresses; j++) {