Skip to content

Commit

Permalink
Stop looping when scheduler receives an AppExit (bevyengine#536)
Browse files Browse the repository at this point in the history
  • Loading branch information
memoryruins authored Sep 20, 2020
1 parent 74dba5f commit fd1d6a3
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions crates/bevy_app/src/schedule_runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,8 @@ impl Plugin for ScheduleRunnerPlugin {

#[cfg(not(target_arch = "wasm32"))]
{
loop {
if let Some(delay) = tick(&mut app, wait) {
thread::sleep(delay);
}
while let Some(delay) = tick(&mut app, wait) {
thread::sleep(delay);
}
}

Expand Down

0 comments on commit fd1d6a3

Please sign in to comment.