diff options
Diffstat (limited to 'contrib/ntp/include/ntp_fp.h')
-rw-r--r-- | contrib/ntp/include/ntp_fp.h | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/contrib/ntp/include/ntp_fp.h b/contrib/ntp/include/ntp_fp.h index 027add3..256bab8 100644 --- a/contrib/ntp/include/ntp_fp.h +++ b/contrib/ntp/include/ntp_fp.h @@ -7,6 +7,7 @@ #include <sys/types.h> #include <sys/socket.h> +#include "ntp_rfc2553.h" #include <netinet/in.h> #include "ntp_types.h" @@ -338,14 +339,13 @@ typedef u_int32 u_fp; /* * Prototypes */ -extern char * dofptoa P((u_fp, int, int, int)); -extern char * dolfptoa P((u_long, u_long, int, int, int)); +extern char * dofptoa P((u_fp, int, short, int)); +extern char * dolfptoa P((u_long, u_long, int, short, int)); extern int atolfp P((const char *, l_fp *)); extern int buftvtots P((const char *, l_fp *)); -extern char * fptoa P((s_fp, int)); -extern char * fptoms P((s_fp, int)); -extern char * fptoms P((s_fp, int)); +extern char * fptoa P((s_fp, short)); +extern char * fptoms P((s_fp, short)); extern int hextolfp P((const char *, l_fp *)); extern void gpstolfp P((int, int, unsigned long, l_fp *)); extern int mstolfp P((const char *, l_fp *)); @@ -361,8 +361,11 @@ extern int adj_systime P((double)); #define lfptoa(_fpv, _ndec) mfptoa((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) #define lfptoms(_fpv, _ndec) mfptoms((_fpv)->l_ui, (_fpv)->l_uf, (_ndec)) -#define ntoa(_sin) numtoa((_sin)->sin_addr.s_addr) -#define ntohost(_sin) numtohost((_sin)->sin_addr.s_addr) +#define stoa(_sin) socktoa((_sin)) +#define stohost(_sin) socktohost((_sin)) + +#define ntoa(_sin) stoa(_sin) +#define ntohost(_sin) stohost(_sin) #define ufptoa(_fpv, _ndec) dofptoa((_fpv), 0, (_ndec), 0) #define ufptoms(_fpv, _ndec) dofptoa((_fpv), 0, (_ndec), 1) |