ntpq peers formatting needs floating point for time slots.

Hal Murray hmurray at megapathdsl.net
Sat Feb 4 22:49:16 UTC 2017


Stromeko at nexgo.de said:
> I don't know how compatible you are trying to stay with the "classic"
> output, but to me it seems you'd be better off with such changes made
> conditional on the use of an option, either a new one or maybe the existing
> '-W' one (which means that the extra space first gets divided up evenly
> between the output fields before finally going to the peers field only). 

The original change that started this thread was simply to change the output 
from %x.3f to %x.4f so Gary could see fractions of a microsecond.  That fits 
much of the time, but also screws up in many cases.  The old code would screw 
 up occasionally, but it was much less often.

It's so close to working reasonably well without an extra flag that a bit of 
kludgery seems worthwhile.

The current code prints out each line as soon as the data is returned from 
the server.  Another approach would be to collect it all so we could scan the 
column and use the 4th digit if everything would fit.

-- 
These are my opinions.  I hate spam.





More information about the devel mailing list