Skip to content

Commit

Permalink
TEST DO NOT MERGE
Browse files Browse the repository at this point in the history
  • Loading branch information
fabricereix committed Oct 29, 2024
1 parent 1ed92a8 commit 09096de
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
12 changes: 6 additions & 6 deletions packages/hurl/src/parallel/runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -278,12 +278,12 @@ impl ParallelRunner {

// We gracefully shut down workers, by dropping the sender and wait for each thread workers
// to join.
drop(self.tx.take());
for worker in &mut self.workers {
if let Some(thread) = worker.0.take_thread() {
thread.join().unwrap();
}
}
// drop(self.tx.take());
// for worker in &mut self.workers {
// if let Some(thread) = worker.0.take_thread() {
// thread.join().unwrap();
// }
// }

// All jobs have been executed, we sort results by sequence number to get the same order
// as the input jobs list.
Expand Down
1 change: 1 addition & 0 deletions packages/hurl/src/parallel/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ impl Worker {
}

/// Takes the thread out of the worker, leaving a None in its place.
#[allow(dead_code)]
pub fn take_thread(&mut self) -> Option<thread::JoinHandle<()>> {
self.thread.take()
}
Expand Down

0 comments on commit 09096de

Please sign in to comment.