summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorterkhen <terkhen@openttd.org>2011-01-15 20:23:15 +0000
committerterkhen <terkhen@openttd.org>2011-01-15 20:23:15 +0000
commit4d8a93c870428d8cdffad9a453aef91a1365f97e (patch)
tree4e2dc2265fdb6922e726991a54525b8b9cc42512 /src
parenta1df4bea6829c1785e8122c3adc915fa3c09964c (diff)
downloadopenttd-4d8a93c870428d8cdffad9a453aef91a1365f97e.tar.xz
(svn r21813) -Fix [FS#4411](r21720): Prevent crash when displaying the owner view.
Diffstat (limited to 'src')
-rw-r--r--src/smallmap_gui.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/smallmap_gui.cpp b/src/smallmap_gui.cpp
index efb3d8df7..84faaefe0 100644
--- a/src/smallmap_gui.cpp
+++ b/src/smallmap_gui.cpp
@@ -544,7 +544,7 @@ static inline uint32 GetSmallMapOwnerPixels(TileIndex tile, TileType t)
*/
}
- if ((o <= MAX_COMPANIES && !_legend_land_owners[_company_to_list_pos[o]].show_on_map) || o == OWNER_NONE) {
+ if ((o < MAX_COMPANIES && !_legend_land_owners[_company_to_list_pos[o]].show_on_map) || o == OWNER_NONE) {
const SmallMapColourScheme *cs = &_heightmap_schemes[_settings_client.gui.smallmap_land_colour];
return _smallmap_show_heightmap ? cs->height_colours[TileHeight(tile)] : cs->default_colour;
} else if (o == OWNER_WATER) {