From ae35a36747837c2a46fa577a5ca99afd21084ad6 Mon Sep 17 00:00:00 2001 From: Amaan Qureshi Date: Sun, 19 May 2024 01:16:58 -0400 Subject: [PATCH] fix(lib): a null clock must have `tv_nsec` be 0 as well --- lib/src/clock.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/clock.h b/lib/src/clock.h index 6e75729e..5d246ca7 100644 --- a/lib/src/clock.h +++ b/lib/src/clock.h @@ -91,7 +91,7 @@ static inline TSClock clock_after(TSClock base, TSDuration duration) { } static inline bool clock_is_null(TSClock self) { - return !self.tv_sec; + return !self.tv_sec && !self.tv_nsec; } static inline bool clock_is_gt(TSClock self, TSClock other) {