diff --git a/r9/src/xtimer.rs b/r9/src/xtimer.rs index 6786fdb..9f21cb6 100644 --- a/r9/src/xtimer.rs +++ b/r9/src/xtimer.rs @@ -261,7 +261,10 @@ impl XTimer { pub fn update(this: &Rc::>) { let tick = (*this.borrow().get_tick_count.as_ref().unwrap())(); let work_list = this.borrow().work_list.clone(); - while this.borrow_mut().fetch_work_list(tick) { + loop { + if !this.borrow_mut().fetch_work_list(tick) { + break; + } while !work_list.borrow().empty() { { let timer = &work_list.borrow().first_entry();