summaryrefslogtreecommitdiff
path: root/aircraft_cmd.c
diff options
context:
space:
mode:
authordarkvater <darkvater@openttd.org>2005-01-30 18:51:08 +0000
committerdarkvater <darkvater@openttd.org>2005-01-30 18:51:08 +0000
commit55e1eab1a212108d5aed57ffe0b98146f52d430c (patch)
tree20759341a92b9f07f715884a092e2aa110489633 /aircraft_cmd.c
parente3287ad30336955b4d84c8fa55002a4e6cb30e1d (diff)
downloadopenttd-55e1eab1a212108d5aed57ffe0b98146f52d430c.tar.xz
(svn r1739) - Fix: type checking when selling vehicles (TrueLight)
Diffstat (limited to 'aircraft_cmd.c')
-rw-r--r--aircraft_cmd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/aircraft_cmd.c b/aircraft_cmd.c
index f832b2776..b66d0d6e7 100644
--- a/aircraft_cmd.c
+++ b/aircraft_cmd.c
@@ -364,7 +364,7 @@ int32 CmdSellAircraft(int x, int y, uint32 flags, uint32 p1, uint32 p2)
v = GetVehicle(p1);
- if (!CheckOwnership(v->owner) || !CheckStoppedInHangar(v))
+ if (v->type != VEH_Aircraft || !CheckOwnership(v->owner) || !CheckStoppedInHangar(v))
return CMD_ERROR;
if (flags & DC_EXEC) {