From 1eb893f361b5cb979fbde4a44e2a744b3a62d4c7 Mon Sep 17 00:00:00 2001 From: florian Date: Sun, 16 Feb 2020 21:04:44 +0000 Subject: The timer type we are using requires interval to be set, remove unused interval_zero. OK millert --- usr.bin/dig/lib/isc/timer.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'usr.bin/dig/lib/isc/timer.c') diff --git a/usr.bin/dig/lib/isc/timer.c b/usr.bin/dig/lib/isc/timer.c index 46953e12524..412918e3df8 100644 --- a/usr.bin/dig/lib/isc/timer.c +++ b/usr.bin/dig/lib/isc/timer.c @@ -14,7 +14,7 @@ * PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: timer.c,v 1.11 2020/02/16 18:05:09 florian Exp $ */ +/* $Id: timer.c,v 1.12 2020/02/16 21:04:44 florian Exp $ */ /*! \file */ @@ -220,8 +220,7 @@ isc__timer_create(isc_timermgr_t *manager0, const struct timespec *interval, REQUIRE(VALID_MANAGER(manager)); REQUIRE(task != NULL); REQUIRE(action != NULL); - if (interval == NULL) - interval = interval_zero; + REQUIRE(interval != NULL); REQUIRE(!(interval_iszero(interval))); REQUIRE(timerp != NULL && *timerp == NULL); @@ -300,10 +299,7 @@ isc__timer_reset(isc_timer_t *timer0, const struct timespec *interval, REQUIRE(VALID_TIMER(timer)); manager = timer->manager; REQUIRE(VALID_MANAGER(manager)); - - if (interval == NULL) - interval = interval_zero; - + REQUIRE(interval != NULL); REQUIRE(!(interval_iszero(interval))); /* -- cgit v1.2.3-59-g8ed1b