[Nagiosplug-devel] [ nagiosplug-Bugs-1468749 ] check_ntp errors when only ntpdate is available

SourceForge.net noreply at sourceforge.net
Tue Jun 6 18:53:06 CEST 2006


Bugs item #1468749, was opened at 2006-04-11 14:29
Message generated for change (Settings changed) made by seanius
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=1468749&group_id=29880

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: General plugin execution
Group: CVS
>Status: Closed
Resolution: None
Priority: 5
Submitted By: Jason Martin (jhmartin)
>Assigned to: M. Sean Finney (seanius)
Summary: check_ntp errors when only ntpdate is available

Initial Comment:
When running check_ntp.pl when only ntpdate is 
available, the jitter value remains at zero and causes 
a divide-by-zero error:

Use of uninitialized value in division (/) 
at ./check_ntp.pl line 437 (my line #'s are different 
due to other changes).

The offending line is:
  print ("NTP $key: $answer|offset=$offset, jitter=" . 
$jitter/1000 .     ",peer_stratum=$stratum\n");

I suggest wrapping the jitter calculation in a 'if 
jitter == 0, then print 0, else print jitter/1000' 
construct.



----------------------------------------------------------------------

Comment By: M. Sean Finney (seanius)
Date: 2006-06-06 12:53

Message:
Logged In: YES 
user_id=226838

this problem is now fixed in cvs.  thank you for your report.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=1468749&group_id=29880




More information about the Devel mailing list