summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vehicle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/vehicle.c b/vehicle.c
index 6881faa4e..165a4ac42 100644
--- a/vehicle.c
+++ b/vehicle.c
@@ -358,7 +358,7 @@ Vehicle *GetPrevVehicleInChain(const Vehicle *v)
{
Vehicle *u;
- FOR_ALL_VEHICLES(u) if (u->next == v) return u;
+ FOR_ALL_VEHICLES(u) if (u->type == VEH_Train && u->next == v) return u;
return NULL;
}