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