From 2b6546c40a7ea7738a3bda81f57e396ab3a305ea Mon Sep 17 00:00:00 2001 From: Ben Wiederhake Date: Sat, 27 Feb 2021 23:56:16 +0100 Subject: Kernel: Make Thread use AK::Time internally This commit is very invasive, because Thread likes to take a pointer and write to it. This means that translating between timespec/timeval/Time would have been more difficult than just changing everything that hands a raw pointer to Thread, in bulk. --- Kernel/TimerQueue.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'Kernel/TimerQueue.h') diff --git a/Kernel/TimerQueue.h b/Kernel/TimerQueue.h index 9d8f87701d..ea3b3bf88e 100644 --- a/Kernel/TimerQueue.h +++ b/Kernel/TimerQueue.h @@ -55,7 +55,7 @@ public: VERIFY(!is_queued()); } - timespec remaining() const; + Time remaining() const; private: TimerId m_id; @@ -92,8 +92,7 @@ public: static TimerQueue& the(); TimerId add_timer(NonnullRefPtr&&); - // FIXME: Should use AK::Time internally - RefPtr add_timer_without_id(clockid_t, const timespec&, Function&&); + RefPtr add_timer_without_id(clockid_t, const Time&, Function&&); TimerId add_timer(clockid_t, timeval& timeout, Function&& callback); bool cancel_timer(TimerId id); bool cancel_timer(Timer&); -- cgit v1.2.3