mirror of
https://github.com/the-tcpdump-group/tcpdump.git
synced 2024-11-30 13:34:04 +08:00
The peer polling interval is an exponent; treat it as such.
RFC 1119 says Peer Poll Interval (peer.ppoll, pkt.ppoll): This is a signed integer indicating the minimum interval between messages sent by the peer, in seconds as a power of two. For instance, a alue of six indicates a minimum interval of 64 seconds. so print both the raw value and 2^{raw value}, showing the latter. Patch from Debian bug 686276. Reviewed-By: Guy Harris <guy@alum.mit.edu>
This commit is contained in:
parent
6ad73bbdf8
commit
6e3dfa3ca3
@ -117,7 +117,7 @@ ntp_print(register const u_char *cp, u_int length)
|
||||
tok2str(ntp_stratum_values, (bp->stratum >=2 && bp->stratum<=15) ? "secondary reference" : "reserved", bp->stratum));
|
||||
|
||||
TCHECK(bp->ppoll);
|
||||
printf(", poll %us", bp->ppoll);
|
||||
printf(", poll %u (%us)", bp->ppoll, 1 << bp->ppoll);
|
||||
|
||||
/* Can't TCHECK bp->precision bitfield so bp->distance + 0 instead */
|
||||
TCHECK2(bp->root_delay, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user