OS X seems particularly picky about possibly uninitialised

variables. Placate its optimiser (again).

[originally from svn r6223]
This commit is contained in:
Simon Tatham
2005-08-27 09:35:14 +00:00
parent 622a5ff678
commit 8c547d5320

View File

@ -304,6 +304,7 @@ static int find_gem_candidates(int w, int h, char *grid,
/* /*
* Find the starting square. * Find the starting square.
*/ */
sx = -1; /* placate optimiser */
for (sy = 0; sy < h; sy++) { for (sy = 0; sy < h; sy++) {
for (sx = 0; sx < w; sx++) for (sx = 0; sx < w; sx++)
if (AT(w, h, grid, sx, sy) == START) if (AT(w, h, grid, sx, sy) == START)