summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortron <tron@openttd.org>2006-02-17 16:42:08 +0000
committertron <tron@openttd.org>2006-02-17 16:42:08 +0000
commit06b6ad92174c8a80db1b911267ea209f09ab5bc5 (patch)
treedc7fffebc90ff508dc7a344d1bd3d9420a408b21
parent784ca2b0e60daf093f4c896ad7c96a6027bbdb11 (diff)
downloadopenttd-06b6ad92174c8a80db1b911267ea209f09ab5bc5.tar.xz
(svn r3610) And one more (see r3608/r3609)
-rw-r--r--vehicle_gui.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/vehicle_gui.c b/vehicle_gui.c
index e46243aca..32c6ad164 100644
--- a/vehicle_gui.c
+++ b/vehicle_gui.c
@@ -571,8 +571,9 @@ static void SetupScrollStuffForReplaceWindow(Window *w)
}
if (selected_id[0] != INVALID_ENGINE) {
- byte cargo = ShipVehInfo(selected_id[0])->cargo_type;
- byte refittable = ShipVehInfo(selected_id[0])->refittable;
+ const ShipVehicleInfo* svi = ShipVehInfo(selected_id[0]);
+ CargoID cargo = svi->cargo_type;
+ byte refittable = svi->refittable;
for (i = SHIP_ENGINES_INDEX; i < SHIP_ENGINES_INDEX + NUM_SHIP_ENGINES; i++) {
if (HASBIT(GetEngine(i)->player_avail, _local_player) && (