die on panic
This commit is contained in:
parent
6b8b361ba8
commit
1f482ab512
1 changed files with 7 additions and 0 deletions
|
@ -30,6 +30,13 @@ fn init_tracing() {
|
||||||
fn init_tracing() {}
|
fn init_tracing() {}
|
||||||
|
|
||||||
fn main() -> glib::ExitCode {
|
fn main() -> glib::ExitCode {
|
||||||
|
// abort on any panic
|
||||||
|
let orig_hook = std::panic::take_hook();
|
||||||
|
std::panic::set_hook(Box::new(move |panic_info| {
|
||||||
|
orig_hook(panic_info);
|
||||||
|
std::process::exit(1);
|
||||||
|
}));
|
||||||
|
|
||||||
gio::resources_register_include!("audrey.gresource").expect("could not register resources");
|
gio::resources_register_include!("audrey.gresource").expect("could not register resources");
|
||||||
|
|
||||||
init_tracing();
|
init_tracing();
|
||||||
|
|
Loading…
Reference in a new issue