daemon: log and exit 1 on startup error, don't panic

This commit is contained in:
Antoine Poinsot committed 2022-12-08 14:59:50 +01:00
1 parent 13b2b8eef4
commit 0306773cdc
1 file changed
+2 -2
+2 -2
View File
@@ -60,8 +60,8 @@ fn main() {
});
let daemon = DaemonHandle::start_default(config).unwrap_or_else(|e| {
// The panic hook will log::error
panic!("Starting Liana daemon: {}", e);
log::error!("Error starting Liana daemon: {}", e);
process::exit(1);
});
daemon
.rpc_server()