Insert explicit warning into the panic hook (#11225)

This commit is contained in:
Anton Gavrilov 2019-10-31 16:17:12 +01:00 committed by GitHub
parent 8c2199dd2a
commit 80754c3426
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -285,6 +285,7 @@ fn main_direct(force_can_restart: bool) -> i32 {
let e = exit.clone(); let e = exit.clone();
let exiting = exiting.clone(); let exiting = exiting.clone();
move |panic_msg| { move |panic_msg| {
warn!("Panic occured, see stderr for details");
eprintln!("{}", panic_msg); eprintln!("{}", panic_msg);
if !exiting.swap(true, Ordering::SeqCst) { if !exiting.swap(true, Ordering::SeqCst) {
*e.0.lock() = ExitStatus { *e.0.lock() = ExitStatus {