diff --git a/src/Main/bootstrap.cxx b/src/Main/bootstrap.cxx index 743fc611a..d9cad75c5 100644 --- a/src/Main/bootstrap.cxx +++ b/src/Main/bootstrap.cxx @@ -188,7 +188,8 @@ int main ( int argc, char **argv ) { // disabled. cerr << "Fatal error: " << t.getFormattedMessage() << "\n (received from " << t.getOrigin() << ')' << endl; - exit(1); + } catch (...) { + cerr << "Unknown exception in the main loop. Aborting..." << endl; } return 0; diff --git a/src/Main/main.cxx b/src/Main/main.cxx index 8f80effbb..42fef6d59 100644 --- a/src/Main/main.cxx +++ b/src/Main/main.cxx @@ -110,7 +110,6 @@ FGGeneral general; int idle_state = 0; long global_multi_loop; - SGTimeStamp last_time_stamp; SGTimeStamp current_time_stamp; @@ -722,6 +721,8 @@ bool fgMainInit( int argc, char **argv ) { exit(-1); } + sgUseDisplayList = fgGetBool( "/sim/rendering/use-display-list", true ); + // Initialize the Aircraft directory to "" (UIUC) aircraft_dir = ""; @@ -938,13 +939,8 @@ bool fgMainInit( int argc, char **argv ) { // build our custom render states globals->get_renderer()->build_states(); - try { - // pass control off to the master event handler - fgOSMainLoop(); - } catch (...) { - SG_LOG( SG_ALL, SG_ALERT, - "Unknown exception in the main loop. Aborting..." ); - } + // pass control off to the master event handler + fgOSMainLoop(); // we never actually get here ... but to avoid compiler warnings, // etc.