Skip to content

Commit

Permalink
Return error code if no task has started successfully
Browse files Browse the repository at this point in the history
  • Loading branch information
nbdd0121 committed Sep 26, 2022
1 parent c6527c2 commit c224798
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions client/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,11 @@ async fn main() {
}));
}

// Return an error code if no task is running.
if tasks.is_empty() {
std::process::exit(1);
}

for task in tasks {
let _ = task.await;
}
Expand Down

0 comments on commit c224798

Please sign in to comment.