Skip to main content

reset_and_snapshot_break_stats_inner

Function reset_and_snapshot_break_stats_inner 

Source
async fn reset_and_snapshot_break_stats_inner(
    stats: &Mutex<BreakStats>,
) -> BreakStats
Expand description

Pure-ish helper: zero the cell under the supplied mutex and return a snapshot of the post-reset value, both atomic to outside writers. Tested in isolation because Scheduler is not constructible in unit tests (it spawns camera/video monitor threads at boot).