diff options
Diffstat (limited to 'plugins/check_ntp_time.c')
| -rw-r--r-- | plugins/check_ntp_time.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/plugins/check_ntp_time.c b/plugins/check_ntp_time.c index 042d3037..ad7f6c4b 100644 --- a/plugins/check_ntp_time.c +++ b/plugins/check_ntp_time.c | |||
| @@ -356,13 +356,13 @@ double offset_request(const char *host, int *status){ | |||
| 356 | ai_tmp = ai_tmp->ai_next; | 356 | ai_tmp = ai_tmp->ai_next; |
| 357 | } | 357 | } |
| 358 | 358 | ||
| 359 | /* now do AVG_NUM checks to each host. we stop before timeout/2 seconds | 359 | /* now do AVG_NUM checks to each host. We stop before timeout/2 seconds |
| 360 | * have passed in order to ensure post-processing and jitter time. */ | 360 | * have passed in order to ensure post-processing and jitter time. */ |
| 361 | now_time=start_ts=time(NULL); | 361 | now_time=start_ts=time(NULL); |
| 362 | while(servers_completed<num_hosts && now_time-start_ts <= socket_timeout/2){ | 362 | while(servers_completed<num_hosts && now_time-start_ts <= socket_timeout/2){ |
| 363 | /* loop through each server and find each one which hasn't | 363 | /* loop through each server and find each one which hasn't |
| 364 | * been touched in the past second or so and is still lacking | 364 | * been touched in the past second or so and is still lacking |
| 365 | * some responses. for each of these servers, send a new request, | 365 | * some responses. For each of these servers, send a new request, |
| 366 | * and update the "waiting" timestamp with the current time. */ | 366 | * and update the "waiting" timestamp with the current time. */ |
| 367 | one_written=0; | 367 | one_written=0; |
| 368 | now_time=time(NULL); | 368 | now_time=time(NULL); |
| @@ -586,11 +586,11 @@ void print_help(void){ | |||
| 586 | 586 | ||
| 587 | printf ("Copyright (c) 2006 Sean Finney\n"); | 587 | printf ("Copyright (c) 2006 Sean Finney\n"); |
| 588 | printf (COPYRIGHT, copyright, email); | 588 | printf (COPYRIGHT, copyright, email); |
| 589 | |||
| 590 | printf ("%s\n", _("This plugin checks the clock offset with the ntp server")); | ||
| 591 | 589 | ||
| 592 | printf ("\n\n"); | 590 | printf ("%s\n", _("This plugin checks the clock offset with the ntp server")); |
| 593 | 591 | ||
| 592 | printf ("\n\n"); | ||
| 593 | |||
| 594 | print_usage(); | 594 | print_usage(); |
| 595 | printf (_(UT_HELP_VRSN)); | 595 | printf (_(UT_HELP_VRSN)); |
| 596 | printf (_(UT_HOST_PORT), 'p', "123"); | 596 | printf (_(UT_HOST_PORT), 'p', "123"); |
| @@ -625,8 +625,8 @@ void print_help(void){ | |||
| 625 | void | 625 | void |
| 626 | print_usage(void) | 626 | print_usage(void) |
| 627 | { | 627 | { |
| 628 | printf (_("Usage:")); | 628 | printf (_("Usage:")); |
| 629 | printf(" %s -H <host> [-w <warn>] [-c <crit>] [-W <warn>] [-C <crit>]\n", progname); | 629 | printf(" %s -H <host> [-w <warn>] [-c <crit>] [-W <warn>] [-C <crit>]\n", progname); |
| 630 | printf(" [-j <warn>] [-k <crit>] [-v verbose]\n"); | 630 | printf(" [-j <warn>] [-k <crit>] [-v verbose]\n"); |
| 631 | } | 631 | } |
| 632 | 632 | ||
