mirror of
https://github.com/rtic-rs/rtic.git
synced 2025-12-18 05:45:19 +01:00
Fix race condition in calculate_now (#860)
* Fix race condition in calculate_now * Add changelog * Update changelog * Refine comment * More comment fixes
This commit is contained in:
parent
f377471e44
commit
bbed945285
8 changed files with 27 additions and 15 deletions
|
|
@ -234,7 +234,7 @@ macro_rules! make_timer {
|
|||
|
||||
fn now() -> Self::Instant {
|
||||
Self::Instant::from_ticks(calculate_now(
|
||||
$overflow.load(Ordering::Relaxed),
|
||||
|| $overflow.load(Ordering::Relaxed),
|
||||
|| $timer.cnt().read().cnt()
|
||||
))
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue