Fix warnings generated by gcc 4.6.0 about variables set but not

thereafter read. Most of these changes are just removal of pointless
stuff or trivial reorganisations; one change is actually substantive,
and fixes a bug in Keen's clue selection (the variable 'bad' was
unreferenced not because I shouldn't have set it, but because I
_should_ have referenced it!).

[originally from svn r9164]
This commit is contained in:
Simon Tatham
2011-05-04 18:22:14 +00:00
parent 4bab5e531b
commit 2efc77d2fd
14 changed files with 31 additions and 54 deletions

View File

@ -3548,7 +3548,6 @@ static void game_redraw_line(drawing *dr, game_drawstate *ds,
grid *g = state->game_grid;
grid_edge *e = g->edges + i;
int x1, x2, y1, y2;
int xmin, ymin, xmax, ymax;
int line_colour;
if (state->line_errors[i])
@ -3568,11 +3567,6 @@ static void game_redraw_line(drawing *dr, game_drawstate *ds,
grid_to_screen(ds, g, e->dot1->x, e->dot1->y, &x1, &y1);
grid_to_screen(ds, g, e->dot2->x, e->dot2->y, &x2, &y2);
xmin = min(x1, x2);
xmax = max(x1, x2);
ymin = min(y1, y2);
ymax = max(y1, y2);
if (line_colour == COL_FAINT) {
static int draw_faint_lines = -1;
if (draw_faint_lines < 0) {