From e93630541de1eb0f4ec9b3474eddf39914ceada2 Mon Sep 17 00:00:00 2001 From: glx22 Date: Sat, 30 Mar 2019 22:12:25 +0100 Subject: [PATCH] Fix #7433: don't use AirportSpec substitute if it's not set (#7435) --- src/newgrf_airport.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/newgrf_airport.cpp b/src/newgrf_airport.cpp index 14af15a371..46f15b0e1c 100644 --- a/src/newgrf_airport.cpp +++ b/src/newgrf_airport.cpp @@ -100,6 +100,7 @@ AirportSpec AirportSpec::specs[NUM_AIRPORTS]; ///< Airport specifications. assert(type < lengthof(AirportSpec::specs)); const AirportSpec *as = &AirportSpec::specs[type]; if (type >= NEW_AIRPORT_OFFSET && !as->enabled) { + if (_airport_mngr.GetGRFID(type) == 0) return as; byte subst_id = _airport_mngr.GetSubstituteID(type); if (subst_id == AT_INVALID) return as; as = &AirportSpec::specs[subst_id];