From f748c82ecf7a98347b6a24ba062a725b4226e8f2 Mon Sep 17 00:00:00 2001 From: YAMAMOTO Takashi Date: Fri, 7 Jul 2023 00:03:21 +0900 Subject: [PATCH] timespec_cmp: assertions --- lib/timeutil.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/timeutil.c b/lib/timeutil.c index 0ee5004e..093e2790 100644 --- a/lib/timeutil.c +++ b/lib/timeutil.c @@ -26,6 +26,8 @@ assert_normalized(const struct timespec *a) int timespec_cmp(const struct timespec *a, const struct timespec *b) { + assert_normalized(a); + assert_normalized(b); if (a->tv_sec == b->tv_sec) { if (a->tv_nsec == b->tv_nsec) { return 0;