diff options
Diffstat (limited to 'usr.sbin/bind/lib/isc/unix/time.c')
| -rw-r--r-- | usr.sbin/bind/lib/isc/unix/time.c | 23 |
1 files changed, 2 insertions, 21 deletions
diff --git a/usr.sbin/bind/lib/isc/unix/time.c b/usr.sbin/bind/lib/isc/unix/time.c index d741d6eeb52..2ebdcc450f2 100644 --- a/usr.sbin/bind/lib/isc/unix/time.c +++ b/usr.sbin/bind/lib/isc/unix/time.c @@ -14,7 +14,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: time.c,v 1.9 2020/01/09 18:17:19 florian Exp $ */ +/* $Id: time.c,v 1.10 2020/01/20 18:44:50 florian Exp $ */ /*! \file */ @@ -34,7 +34,7 @@ #include <isc/strerror.h> #include <isc/string.h> #include <isc/time.h> -#include <isc/tm.h> + #include <isc/util.h> #define NS_PER_S 1000000000 /*%< Nanoseconds per second. */ @@ -419,25 +419,6 @@ isc_time_formathttptimestamp(const isc_time_t *t, char *buf, unsigned int len) { INSIST(flen < len); } -isc_result_t -isc_time_parsehttptimestamp(char *buf, isc_time_t *t) { - struct tm t_tm; - time_t when; - char *p; - - REQUIRE(buf != NULL); - REQUIRE(t != NULL); - - p = isc_tm_strptime(buf, "%a, %d %b %Y %H:%M:%S", &t_tm); - if (p == NULL) - return (ISC_R_UNEXPECTED); - when = isc_tm_timegm(&t_tm); - if (when == -1) - return (ISC_R_UNEXPECTED); - isc_time_set(t, when, 0); - return (ISC_R_SUCCESS); -} - void isc_time_formatISO8601(const isc_time_t *t, char *buf, unsigned int len) { time_t now; |
