diff options
-rw-r--r-- | src/cargotype.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/cargotype.cpp b/src/cargotype.cpp index d89972c31..bea8edd65 100644 --- a/src/cargotype.cpp +++ b/src/cargotype.cpp @@ -64,6 +64,7 @@ bool CargoSpec::IsValid() const CargoID GetCargoIDByLabel(CargoLabel cl) { for (CargoID c = 0; c < lengthof(_cargo); c++) { + if (_cargo[c].bitnum == INVALID_CARGO) continue; if (_cargo[c].label == cl) return c; } |