// in fg_init.cxx, and are just here temporarily until some rationalisation occurs.
// find basic airport location info from airport database
bool dclFindAirportID( const string& id, FGAirport *a ) {
- FGAirport result;
+ const FGAirport* result;
if ( id.length() ) {
SG_LOG( SG_GENERAL, SG_INFO, "Searching for airport code = " << id );
- result = globals->get_airports()->search( id );
- if ( result.getId().empty() ) {
+ result = globals->get_airports()->search(id);
+ if ( result == NULL ) {
SG_LOG( SG_GENERAL, SG_WARN,
- "Failed to find " << id << " in basic.dat.gz" );
+ "Failed to find " << id << " in apt.dat.gz" );
return false;
}
} else {
return false;
}
- *a = result;
+ *a = *result;
SG_LOG( SG_GENERAL, SG_INFO,
"Position for " << id << " is ("