1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-11-23 13:07:16 +00:00

log exceptions not caught

This commit is contained in:
Zeno Rogue 2024-10-20 01:51:55 +02:00
parent 6c47ba501b
commit c6c400ffc3

View File

@ -77,6 +77,7 @@ EX void hyper_loop() {
} }
EX int hyper_main(int argc, char **argv) { EX int hyper_main(int argc, char **argv) {
try {
if(!hyper_init(argc, argv)) return 0; if(!hyper_init(argc, argv)) return 0;
#if !ISWEB #if !ISWEB
if(showstartmenu && !vid.skipstart) { if(showstartmenu && !vid.skipstart) {
@ -88,7 +89,11 @@ EX int hyper_main(int argc, char **argv) {
#endif #endif
progress_warning(); progress_warning();
mainloop(); mainloop();
finishAll(); finishAll();
} catch(hr_exception& e) {
println(hlog, "exception not caught: ", e.what());
}
fflush(stdout);
return 0; return 0;
} }
} }