diff options
Diffstat (limited to 'usr.bin/dig/lib/isc/unix')
| -rw-r--r-- | usr.bin/dig/lib/isc/unix/include/isc/time.h | 10 | ||||
| -rw-r--r-- | usr.bin/dig/lib/isc/unix/time.c | 18 |
2 files changed, 4 insertions, 24 deletions
diff --git a/usr.bin/dig/lib/isc/unix/include/isc/time.h b/usr.bin/dig/lib/isc/unix/include/isc/time.h index e225b7292c4..5d294edfe60 100644 --- a/usr.bin/dig/lib/isc/unix/include/isc/time.h +++ b/usr.bin/dig/lib/isc/unix/include/isc/time.h @@ -14,7 +14,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: time.h,v 1.14 2020/02/16 21:11:02 florian Exp $ */ +/* $Id: time.h,v 1.15 2020/02/16 21:11:31 florian Exp $ */ #ifndef ISC_TIME_H #define ISC_TIME_H 1 @@ -22,13 +22,9 @@ /*! \file */ #include <sys/time.h> -#include <time.h> -#include <isc/types.h> - -/*** - *** Absolute Times - ***/ +#include <inttypes.h> +#include <time.h> uint64_t isc_time_microdiff(const struct timespec *t1, const struct timespec *t2); diff --git a/usr.bin/dig/lib/isc/unix/time.c b/usr.bin/dig/lib/isc/unix/time.c index ed4e821cd73..d073515bfbd 100644 --- a/usr.bin/dig/lib/isc/unix/time.c +++ b/usr.bin/dig/lib/isc/unix/time.c @@ -14,17 +14,12 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: time.c,v 1.17 2020/02/16 21:11:02 florian Exp $ */ +/* $Id: time.c,v 1.18 2020/02/16 21:11:31 florian Exp $ */ /*! \file */ #include <sys/time.h> - -#include <errno.h> -#include <limits.h> -#include <stdio.h> #include <time.h> -#include <string.h> #include <isc/time.h> #include <isc/util.h> @@ -32,17 +27,6 @@ #define NS_PER_S 1000000000 /*%< Nanoseconds per second. */ #define NS_PER_US 1000 /*%< Nanoseconds per microsecond. */ -/* - * All of the INSIST()s checks of nanoseconds < NS_PER_S are for - * consistency checking of the type. In lieu of magic numbers, it - * is the best we've got. The check is only performed on functions which - * need an initialized type. - */ - -/*** - *** Absolute Times - ***/ - uint64_t isc_time_microdiff(const struct timespec *t1, const struct timespec *t2) { struct timespec res; |
