]> git.mxchange.org Git - flightgear.git/commitdiff
Fix another possible ATC stackdump
authordaveluff <daveluff>
Mon, 22 Mar 2004 22:09:47 +0000 (22:09 +0000)
committerdaveluff <daveluff>
Mon, 22 Mar 2004 22:09:47 +0000 (22:09 +0000)
src/ATC/tower.cxx

index c4ccc96bbf59b9378a6c18f0f22d918ec5490268..b68bd53ed9d186941132caf6adc98f60d9d47a90 100644 (file)
@@ -649,13 +649,19 @@ void FGTower::ProcessDownwindReport(TowerPlaneRec* t) {
                s = s.substr(0,p);
                trns += s;
                if((tt->opType) == CIRCUIT) {
-                       if(tt->planePtr->GetLeg() == FINAL) {
+                       PatternLeg leg;
+                       if(t->isUser) {
+                               leg = tt->leg;
+                       } else {
+                               leg = tt->planePtr->GetLeg();
+                       }
+                       if(leg == FINAL) {
                                trns += " on final";
-                       } else if(tt->planePtr->GetLeg() == TURN4) {
+                       } else if(leg == TURN4) {
                                trns += " turning final";
-                       } else if(tt->planePtr->GetLeg() == BASE) {
+                       } else if(leg == BASE) {
                                trns += " on base";
-                       } else if(tt->planePtr->GetLeg() == TURN3) {
+                       } else if(leg == TURN3) {
                                trns += " turning base";
                        }
                } else {