From ccecba33a2b32e607b2d008a69a90f6532926374 Mon Sep 17 00:00:00 2001 From: Jan Wagner Date: Fri, 24 Jan 2014 18:20:08 +0100 Subject: Fixing bug in average calculation (Submitted by Lars) The more important change: A fix for a bug which caused the check_ntp_time and check_ntp_time check to always take the first response from ntp and not the avarage since "j" is not increased anywhere. "i" should be used there instead. Partly Closes #956 and Closes #1166 Closes: #1089 --- plugins/check_ntp.c | 2 +- plugins/check_ntp_time.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/check_ntp.c b/plugins/check_ntp.c index 6607b4b4..0a7640a7 100644 --- a/plugins/check_ntp.c +++ b/plugins/check_ntp.c @@ -482,7 +482,7 @@ double offset_request(const char *host, int *status){ } else { /* finally, calculate the average offset */ for(i=0; i