summaryrefslogtreecommitdiff
path: root/src/bin/br
diff options
context:
space:
mode:
Diffstat (limited to 'src/bin/br')
-rw-r--r--src/bin/br/main.rs9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/bin/br/main.rs b/src/bin/br/main.rs
index 11505cb..da11a18 100644
--- a/src/bin/br/main.rs
+++ b/src/bin/br/main.rs
@@ -130,8 +130,8 @@ fn main() {
symbols_path, name, identifier, title, icon,
};
- if let Ok(phosphor) = Phosphor::new() {
- match mode {
+ match Phosphor::new() {
+ Ok(phosphor) => match mode {
Mode::Dynamic => {
info!("Starting graphical emulator (hidden)");
let mut emulator = GraphicalEmulator::new(config, debug);
@@ -151,9 +151,9 @@ fn main() {
emulator.run();
}
}
- } else {
- match mode {
+ Err(err) => match mode {
Mode::Dynamic => {
+ eprintln!("EventLoopError: {err:?}");
info!("Could not start graphical event loop");
info!("Starting headless emulator");
let mut emulator = HeadlessEmulator::new(&config, debug);
@@ -161,6 +161,7 @@ fn main() {
emulator.run();
}
Mode::Graphical => {
+ eprintln!("EventLoopError: {err:?}");
fatal!("Could not start graphical event loop");
}
Mode::Headless => {