xref: /netbsd-src/external/bsd/ntp/dist/sntp/utilities.h (revision 7788a0781fe6ff2cce37368b4578a7ade0850cb1)
1 /*	$NetBSD: utilities.h,v 1.1.1.2 2012/01/31 21:27:42 kardel Exp $	*/
2 
3 #ifndef UTILITIES_H
4 #define UTILITIES_H
5 
6 #include <math.h>
7 #include <stdio.h>
8 #include <stdlib.h>
9 #include <ntp_stdlib.h>
10 #include <ntp_fp.h>
11 #include <ntp.h>
12 
13 #define HLINE "--------------------------------------------------------------------------------\n"
14 #define PHLINE fprintf(output, HLINE);
15 #define STDLINE printf(HLINE);
16 
17 
18 void pkt_output (struct pkt *dpkg, int pkt_length, FILE *output);
19 void l_fp_output (l_fp *ts, FILE *output);
20 void l_fp_output_bin (l_fp *ts, FILE *output);
21 void l_fp_output_dec (l_fp *ts, FILE *output);
22 
23 char *addrinfo_to_str (struct addrinfo *addr);
24 char *ss_to_str (sockaddr_u *saddr);
25 char *tv_to_str (const struct timeval *tv);
26 
27 #endif
28