1
0
Fork 0

Don't catch a (potentially) meaningful exception only to replace it with

a meaningless one. bootstrap.cxx/main() will catch it, anyway.
This commit is contained in:
mfranz 2007-06-16 16:25:40 +00:00
parent c5a3f570f8
commit b502cef066

View file

@ -1327,7 +1327,6 @@ void fgInitFDM() {
double dt = 1.0 / fgGetInt("/sim/model-hz");
string model = fgGetString("/sim/flight-model");
try {
if ( model == "larcsim" ) {
cur_fdm_state = new FGLaRCsim( dt );
} else if ( model == "jsb" ) {
@ -1403,14 +1402,8 @@ void fgInitFDM() {
} else if ( model == "yasim" ) {
cur_fdm_state = new YASim( dt );
} else {
SG_LOG(SG_GENERAL, SG_ALERT,
"Unrecognized flight model '" << model
<< "', cannot init flight dynamics model.");
exit(-1);
}
} catch ( ... ) {
SG_LOG(SG_GENERAL, SG_ALERT, "FlightGear aborting\n\n");
exit(-1);
throw sg_throwable(string("Unrecognized flight model '") + model
+ "', cannot init flight dynamics model.");
}
}