Fix for Martin: tolerate runway-associated navaids with a bogus ICAO/runway ident.
This commit is contained in:
parent
9bc4c938d2
commit
718d99f420
2 changed files with 5 additions and 3 deletions
|
@ -240,11 +240,10 @@ FGRunway* getRunwayFromName(const std::string& aName)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
FGRunway* runway = apt->getRunwayByIdent(parts[1]);
|
if (!apt->hasRunwayWithIdent(parts[1])) {
|
||||||
if (!runway) {
|
|
||||||
SG_LOG(SG_GENERAL, SG_WARN, "navaid " << aName << " associated with bogus runway ID:" << parts[1]);
|
SG_LOG(SG_GENERAL, SG_WARN, "navaid " << aName << " associated with bogus runway ID:" << parts[1]);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
return runway;
|
return apt->getRunwayByIdent(parts[1]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -91,6 +91,9 @@ void FGNavRecord::initAirportRelation()
|
||||||
}
|
}
|
||||||
|
|
||||||
mRunway = getRunwayFromName(_name);
|
mRunway = getRunwayFromName(_name);
|
||||||
|
if (!mRunway) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (type() != GS) {
|
if (type() != GS) {
|
||||||
readAirportSceneryData();
|
readAirportSceneryData();
|
||||||
|
|
Loading…
Reference in a new issue