From 0d06a62dd1bffe72b93f3a03c9cbfb57dcb2c20b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Wed, 25 Mar 2020 19:06:50 +0100 Subject: [PATCH] Fix the tv_nsec check in isc_stdtime_get() --- lib/isc/unix/stdtime.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/isc/unix/stdtime.c b/lib/isc/unix/stdtime.c index a68ad31b17..80e9f25547 100644 --- a/lib/isc/unix/stdtime.c +++ b/lib/isc/unix/stdtime.c @@ -45,7 +45,7 @@ isc_stdtime_get(isc_stdtime_t *t) { strbuf); } - REQUIRE(ts.tv_sec > 0 && ts.tv_nsec > 0 && ts.tv_nsec < NS_PER_S); + REQUIRE(ts.tv_sec > 0 && ts.tv_nsec >= 0 && ts.tv_nsec < NS_PER_S); *t = (unsigned int)ts.tv_sec; }