4 * buftvtots - pull a Unix-format (struct timeval) time stamp out of
5 * an octet stream and convert it to a l_fp time stamp.
6 * This is useful when using the clock line discipline.
13 #include "ntp_string.h"
14 #include "ntp_unixtime.h"
26 * copy to adhere to alignment restrictions
28 memcpy(&tv
, bufp
, sizeof(tv
));
33 ts
->l_ui
= tv
.tv_sec
+ (u_long
)JAN_1970
;
34 if (tv
.tv_usec
> 999999)
36 TVUTOTSF(tv
.tv_usec
, ts
->l_uf
);
41 * Windows doesn't have the tty_clock line discipline, so
42 * don't look for a timestamp where there is none.
55 #endif /* SYS_WINNT */