mirror of
https://github.com/embassy-rs/embassy.git
synced 2024-11-25 16:23:10 +00:00
Allow clearing finished task from timer queue
This commit is contained in:
parent
d8c7c3fc4b
commit
a2501bd5c1
@ -165,6 +165,9 @@ impl<F: Future + 'static> TaskStorage<F> {
|
||||
Poll::Ready(_) => {
|
||||
this.future.drop_in_place();
|
||||
this.raw.state.fetch_and(!STATE_SPAWNED, Ordering::AcqRel);
|
||||
|
||||
#[cfg(feature = "integrated-timers")]
|
||||
this.raw.expires_at.set(Instant::MAX);
|
||||
}
|
||||
Poll::Pending => {}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user