mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-07-17 17:35:19 +01:00
(svn r3599) -Fix: added some casts to suppress some more warnings
This commit is contained in:
parent
0068f19605
commit
604a1a9974
@ -559,7 +559,7 @@ static bool NtpVisit(NewTrackPathFinder *tpf, TileIndex tile, uint dir, uint len
|
|||||||
do {
|
do {
|
||||||
link = NTP_GET_LINK_PTR(tpf, offs);
|
link = NTP_GET_LINK_PTR(tpf, offs);
|
||||||
if (tile == link->tile && (link->typelength & 0x3U) == dir) {
|
if (tile == link->tile && (link->typelength & 0x3U) == dir) {
|
||||||
if (length >= link->typelength >> 2) return false;
|
if (length >= (uint)(link->typelength >> 2)) return false;
|
||||||
link->typelength = dir | (length << 2);
|
link->typelength = dir | (length << 2);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -612,8 +612,8 @@ static bool NtpCheck(NewTrackPathFinder *tpf, TileIndex tile, uint dir, uint len
|
|||||||
for (;;) {
|
for (;;) {
|
||||||
link = NTP_GET_LINK_PTR(tpf, offs);
|
link = NTP_GET_LINK_PTR(tpf, offs);
|
||||||
if (tile == link->tile && (link->typelength & 0x3U) == dir) {
|
if (tile == link->tile && (link->typelength & 0x3U) == dir) {
|
||||||
assert(link->typelength >> 2 <= length);
|
assert((uint)(link->typelength >> 2) <= length);
|
||||||
return length == link->typelength >> 2;
|
return length == (uint)(link->typelength >> 2);
|
||||||
}
|
}
|
||||||
offs = link->next;
|
offs = link->next;
|
||||||
assert(offs != 0xffff);
|
assert(offs != 0xffff);
|
||||||
|
Loading…
Reference in New Issue
Block a user