Tidied up exit (return code instead of printing ugly message)
This commit is contained in:
parent
b88d0fb5fd
commit
60a428443e
|
@ -239,7 +239,10 @@ CApp::run(int argc, char** argv, CreateTaskBarReceiverFunc createTaskBarReceiver
|
||||||
result = ARCH->run(argc, argv, createTaskBarReceiver);
|
result = ARCH->run(argc, argv, createTaskBarReceiver);
|
||||||
}
|
}
|
||||||
catch (XExitApp& e) {
|
catch (XExitApp& e) {
|
||||||
LOG((CLOG_WARN "Forced exit: %s\n", e.what()));
|
// instead of showing a nasty error, just exit with the error code.
|
||||||
|
// not sure if i like this behaviour, but it's probably better than
|
||||||
|
// using the exit(int) function!
|
||||||
|
result = e.getCode();
|
||||||
}
|
}
|
||||||
catch (XBase& e) {
|
catch (XBase& e) {
|
||||||
LOG((CLOG_CRIT "Exception: %s\n", e.what()));
|
LOG((CLOG_CRIT "Exception: %s\n", e.what()));
|
||||||
|
|
Loading…
Reference in New Issue