diff options
author | Holger Weiss <holger@zedat.fu-berlin.de> | 2013-09-29 22:03:24 (GMT) |
---|---|---|
committer | Holger Weiss <holger@zedat.fu-berlin.de> | 2013-09-29 22:03:24 (GMT) |
commit | 0b6423f9c99d9edf8c96fefd0f6c453859395aa1 (patch) | |
tree | 1c2b6b21704a294940f87c7892676998d8371707 /web/attachments/260847-check_ntp_time.best_offset_server_fix.patch | |
download | site-0b6423f9c99d9edf8c96fefd0f6c453859395aa1.tar.gz |
Import Nagios Plugins site
Import the Nagios Plugins web site, Cronjobs, infrastructure scripts,
and configuration files.
Diffstat (limited to 'web/attachments/260847-check_ntp_time.best_offset_server_fix.patch')
-rw-r--r-- | web/attachments/260847-check_ntp_time.best_offset_server_fix.patch | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/web/attachments/260847-check_ntp_time.best_offset_server_fix.patch b/web/attachments/260847-check_ntp_time.best_offset_server_fix.patch new file mode 100644 index 0000000..c542da0 --- /dev/null +++ b/web/attachments/260847-check_ntp_time.best_offset_server_fix.patch | |||
@@ -0,0 +1,21 @@ | |||
1 | Index: plugins/check_ntp_time.c | ||
2 | =================================================================== | ||
3 | --- plugins/check_ntp_time.c (revision 1885) | ||
4 | +++ plugins/check_ntp_time.c (working copy) | ||
5 | @@ -274,7 +274,7 @@ | ||
6 | /* if we haven't reached the current list's end, move everyone | ||
7 | * over one to the right, and insert the new candidate */ | ||
8 | if(i<csize){ | ||
9 | - for(j=5; j>i; j--){ | ||
10 | + for(j=4; j>i; j--){ | ||
11 | candidates[j]=candidates[j-1]; | ||
12 | } | ||
13 | } | ||
14 | @@ -337,6 +337,7 @@ | ||
15 | servers=(ntp_server_results*)malloc(sizeof(ntp_server_results)*num_hosts); | ||
16 | if(servers==NULL) die(STATE_UNKNOWN, "can not allocate server array"); | ||
17 | memset(servers, 0, sizeof(ntp_server_results)*num_hosts); | ||
18 | + DBG(printf("Found %d peers to check\n", num_hosts)); | ||
19 | |||
20 | /* setup each socket for writing, and the corresponding struct pollfd */ | ||
21 | ai_tmp=ai; | ||