summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/train.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/train.h b/src/train.h
index 27e232935..0e92a962c 100644
--- a/src/train.h
+++ b/src/train.h
@@ -255,7 +255,7 @@ static inline Vehicle *GetNextUnit(Vehicle *v)
{
assert(v->type == VEH_TRAIN);
v = GetNextVehicle(v);
- if (v != NULL && IsRearDualheaded(v)) v = v->Next();
+ if (v != NULL && IsRearDualheaded(v)) v = GetNextVehicle(v);
return v;
}