diff options
author | Rubidium <rubidium@openttd.org> | 2021-05-10 23:43:52 +0200 |
---|---|---|
committer | rubidium42 <rubidium42@users.noreply.github.com> | 2021-05-15 10:16:10 +0200 |
commit | bb9121dbd4690405b54e7e6ed6e711ead16435ac (patch) | |
tree | efb930ab320c6be74d4ca8e4d5d674e3d1e7812d /src/rail_gui.cpp | |
parent | 031e91de6e06e6b0d12603d78170f92f5def1d00 (diff) | |
download | openttd-bb9121dbd4690405b54e7e6ed6e711ead16435ac.tar.xz |
Fix: comparison of narrow type to wide type in loop (potential for infinite loops)
Diffstat (limited to 'src/rail_gui.cpp')
-rw-r--r-- | src/rail_gui.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rail_gui.cpp b/src/rail_gui.cpp index 49c7d736a..3cb99d785 100644 --- a/src/rail_gui.cpp +++ b/src/rail_gui.cpp @@ -1219,7 +1219,7 @@ public: StringID str = this->GetWidget<NWidgetCore>(widget)->widget_data; for (auto station_class : this->station_classes) { StationClass *stclass = StationClass::Get(station_class); - for (uint16 j = 0; j < stclass->GetSpecCount(); j++) { + for (uint j = 0; j < stclass->GetSpecCount(); j++) { const StationSpec *statspec = stclass->GetSpec(j); SetDParam(0, (statspec != nullptr && statspec->name != 0) ? statspec->name : STR_STATION_CLASS_DFLT); d = maxdim(d, GetStringBoundingBox(str)); |