Remove a bunch of redundant casts.

This commit is contained in:
Markus Armbruster 2005-06-12 06:31:48 +00:00
parent ee6d72f3b8
commit 4f59fc9967
125 changed files with 417 additions and 432 deletions

View file

@ -80,15 +80,14 @@ path(void)
return RET_FAIL;
}
if (!mapbuf)
mapbuf =
(s_char *)malloc((WORLD_Y * MAPWIDTH(3)) * sizeof(s_char));
mapbuf = malloc((WORLD_Y * MAPWIDTH(3)) * sizeof(s_char));
if (!map) {
map = (s_char **)malloc(WORLD_Y * sizeof(s_char *));
map = malloc(WORLD_Y * sizeof(s_char *));
if (map && mapbuf) {
for (i = 0; i < WORLD_Y; i++)
map[i] = &mapbuf[MAPWIDTH(3) * i];
} else if (map) {
free((s_char *)map);
free(map);
map = (s_char **)0;
}
}