1
0
Fork 0

Merge branch 'jmt/runway-fix'

This commit is contained in:
Tim Moore 2010-05-06 11:03:23 +02:00
commit 78d9cacead

View file

@ -225,7 +225,13 @@ void RunwayGroup::setActive(const FGAirport* airport,
validSelection = true; validSelection = true;
for (int j = 0; j < activeRwys; j++) for (int j = 0; j < activeRwys; j++)
{ {
rwy = airport->getRunwayByIdent(rwyList[j].getRwyList(i)); string ident(rwyList[j].getRwyList(i));
if (!airport->hasRunwayWithIdent(ident)) {
SG_LOG(SG_GENERAL, SG_WARN, "no such runway:" << ident << " at " << airport->ident());
continue;
}
rwy = airport->getRunwayByIdent(ident);
//cerr << "Succes" << endl; //cerr << "Succes" << endl;
hdgDiff = fabs(windHeading - rwy->headingDeg()); hdgDiff = fabs(windHeading - rwy->headingDeg());