aboutsummaryrefslogtreecommitdiff
path: root/crates/thread_worker/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/thread_worker/src')
-rw-r--r--crates/thread_worker/src/lib.rs9
1 files changed, 3 insertions, 6 deletions
diff --git a/crates/thread_worker/src/lib.rs b/crates/thread_worker/src/lib.rs
index d67e44e38..d8d0d9bf2 100644
--- a/crates/thread_worker/src/lib.rs
+++ b/crates/thread_worker/src/lib.rs
@@ -19,13 +19,10 @@ impl Drop for ScopedThread {
19 log::info!(".. {} terminated with {}", name, if res.is_ok() { "ok" } else { "err" }); 19 log::info!(".. {} terminated with {}", name, if res.is_ok() { "ok" } else { "err" });
20 20
21 // escalate panic, but avoid aborting the process 21 // escalate panic, but avoid aborting the process
22 match res { 22 if let Err(e) = res {
23 Err(e) => { 23 if !thread::panicking() {
24 if !thread::panicking() { 24 panic!(e)
25 panic!(e)
26 }
27 } 25 }
28 _ => (),
29 } 26 }
30 } 27 }
31} 28}