summaryrefslogtreecommitdiffstats
path: root/usr.sbin/timed
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1994-11-27 16:06:31 +0000
committerbde <bde@FreeBSD.org>1994-11-27 16:06:31 +0000
commit29fef6468141bce7f02781c735c8d9ddb60b2123 (patch)
treeb935d30b5a2912589a71143b66ff01bf7cf606cb /usr.sbin/timed
parentd8f82d91645ef1c0324bd8935254a0aa2886b23d (diff)
downloadFreeBSD-src-29fef6468141bce7f02781c735c8d9ddb60b2123.zip
FreeBSD-src-29fef6468141bce7f02781c735c8d9ddb60b2123.tar.gz
Apply an even number of ntohl's to icmp_otime. This fixes
`timedc clockdiff ...'.
Diffstat (limited to 'usr.sbin/timed')
-rw-r--r--usr.sbin/timed/timed/measure.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/timed/timed/measure.c b/usr.sbin/timed/timed/measure.c
index 4066d10..c8535a4 100644
--- a/usr.sbin/timed/timed/measure.c
+++ b/usr.sbin/timed/timed/measure.c
@@ -36,7 +36,7 @@ static char sccsid[] = "@(#)measure.c 8.1 (Berkeley) 6/6/93";
#endif /* not lint */
#ifdef sgi
-#ident "$Revision: 1.8 $"
+#ident "$Revision: 1.1.1.1 $"
#endif
#include "globals.h"
@@ -151,8 +151,8 @@ measure(maxmsec, wmsec, hname, addr, print)
*/
if (trials < TRIALS) {
trials++;
- oicp->icmp_otime = ((tcur.tv_sec % SECDAY) * 1000
- + tcur.tv_usec / 1000);
+ oicp->icmp_otime = ntohl((tcur.tv_sec % SECDAY) * 1000
+ + tcur.tv_usec / 1000);
oicp->icmp_cksum = 0;
oicp->icmp_cksum = in_cksum((u_short*)oicp,
sizeof(*oicp));
OpenPOWER on IntegriCloud