summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordarkvater <darkvater@openttd.org>2005-01-09 18:59:16 +0000
committerdarkvater <darkvater@openttd.org>2005-01-09 18:59:16 +0000
commitfbcc84bdcf565164ef3f5a42985c2d865015b20d (patch)
treef32ed4d612256d31584d6c1ae97c69856b0b52c5
parent97479f96134ec155375f97a8d12b0f8c4517a7a2 (diff)
downloadopenttd-fbcc84bdcf565164ef3f5a42985c2d865015b20d.tar.xz
(svn r1449) -Fix: signed/unsigned error on windows
-Change: Makefile added -Wsign-compare flag
-rw-r--r--Makefile2
-rw-r--r--map.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 9bca5ab52..355583fb9 100644
--- a/Makefile
+++ b/Makefile
@@ -290,7 +290,7 @@ endif
# -O optimize or -O2 fully optimize (O's above 2 are not recommended)
# -pg profile - generate profiling data. See "man gprof" to use this.
-CFLAGS=-Wall -Wno-multichar
+CFLAGS=-Wall -Wno-multichar -Wsign-compare
CDEFS=-DWITH_REV
LDFLAGS=
LIBS=
diff --git a/map.c b/map.c
index a158dd6de..81a72b28b 100644
--- a/map.c
+++ b/map.c
@@ -29,7 +29,7 @@ TileIndex TileAdd(TileIndex tile, TileIndexDiff add,
uint y;
dx = add & MapMaxX();
- if (dx >= MapSizeX() / 2) dx -= MapSizeX();
+ if (dx >= (int)MapSizeX() / 2) dx -= MapSizeX();
dy = (add - dx) / (int)MapSizeX();
x = TileX(tile) + dx;