Exit application with non-zero general error status code if an exception is raised
This commit is contained in:
parent
e0b9e29db9
commit
400891fcfe
|
@ -130,9 +130,11 @@ int main( int argc, char ** argv )
|
|||
}
|
||||
catch (const Base::Exception& e) {
|
||||
e.ReportException();
|
||||
exit(1);
|
||||
}
|
||||
catch (...) {
|
||||
Console().Error("Application unexpectedly terminated\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Destruction phase ===========================================================
|
||||
|
|
|
@ -241,9 +241,11 @@ int main( int argc, char ** argv )
|
|||
}
|
||||
catch (const Base::Exception& e) {
|
||||
e.ReportException();
|
||||
exit(1);
|
||||
}
|
||||
catch (...) {
|
||||
Base::Console().Error("Application unexpectedly terminated\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
std::cout.rdbuf(oldcout);
|
||||
|
|
Loading…
Reference in New Issue
Block a user