2 * buftvtots - pull a Unix-format (struct timeval) time stamp out of
3 * an octet stream and convert it to a l_fp time stamp.
4 * This is useful when using the clock line discipline.
11 #include "ntp_string.h"
12 #include "ntp_unixtime.h"
23 * copy to adhere to alignment restrictions
25 memcpy(&tv, bufp, sizeof(tv));
30 ts->l_ui = tv.tv_sec + (u_long)JAN_1970;
31 if (tv.tv_usec > 999999)
33 TVUTOTSF(tv.tv_usec, ts->l_uf);