Parking: another segfault edge-case.
Again, when there's no parking/ground-net, tolerate this.
This commit is contained in:
parent
6c6452c62b
commit
fb266722ba
1 changed files with 8 additions and 0 deletions
|
@ -1012,6 +1012,14 @@ bool FGAIFlightPlan::createParking(FGAIAircraft * ac, FGAirport * apt,
|
||||||
double vTaxi = ac->getPerformance()->vTaxi();
|
double vTaxi = ac->getPerformance()->vTaxi();
|
||||||
double vTaxiReduced = vTaxi * (2.0 / 3.0);
|
double vTaxiReduced = vTaxi * (2.0 / 3.0);
|
||||||
FGParking* parking = apt->getDynamics()->getParking(gateId);
|
FGParking* parking = apt->getDynamics()->getParking(gateId);
|
||||||
|
if (!parking) {
|
||||||
|
wpt = createOnGround(ac, "END-Parking", apt->geod(), aptElev,
|
||||||
|
vTaxiReduced);
|
||||||
|
pushBackWaypoint(wpt);
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
double heading = SGMiscd::normalizePeriodic(0, 360, parking->getHeading() + 180.0);
|
double heading = SGMiscd::normalizePeriodic(0, 360, parking->getHeading() + 180.0);
|
||||||
double az; // unused
|
double az; // unused
|
||||||
SGGeod pos;
|
SGGeod pos;
|
||||||
|
|
Loading…
Add table
Reference in a new issue