mirror of https://github.com/OpenTTD/OpenTTD
(svn r1557) Replace strange if () do while () construct with a plain for ()
parent
5bcf3d2bc0
commit
eaa6bf3f42
4
gfx.c
4
gfx.c
|
@ -23,11 +23,11 @@ void memcpy_pitch(void *d, void *s, int w, int h, int spitch, int dpitch)
|
||||||
byte *sp = (byte*)s;
|
byte *sp = (byte*)s;
|
||||||
|
|
||||||
assert(h >= 0);
|
assert(h >= 0);
|
||||||
if (h != 0) do {
|
for (; h != 0; --h) {
|
||||||
memcpy(dp, sp, w);
|
memcpy(dp, sp, w);
|
||||||
dp += dpitch;
|
dp += dpitch;
|
||||||
sp += spitch;
|
sp += spitch;
|
||||||
} while (--h);
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue