mirror of
git://git.tartarus.org/simon/puzzles.git
synced 2025-04-20 15:41:30 -07:00
Fix some unused-variable warnings.
A test-build with a modern clang points out a number of 'set but not used' variables, which clang seems to have got better at recently. In cases where there's conditioned-out or commented-out code using the variable, I've left it in and added a warning-suppressing cast to void. Otherwise I've just deleted the variables.
This commit is contained in:
@ -663,7 +663,7 @@ static bool solve_puzzle(const game_state *state, unsigned char *grid,
|
||||
#ifndef STANDALONE_PICTURE_GENERATOR
|
||||
static unsigned char *generate_soluble(random_state *rs, int w, int h)
|
||||
{
|
||||
int i, j, ntries, max;
|
||||
int i, j, max;
|
||||
bool ok;
|
||||
unsigned char *grid, *matrix, *workspace;
|
||||
unsigned int *changed_h, *changed_w;
|
||||
@ -679,11 +679,7 @@ static unsigned char *generate_soluble(random_state *rs, int w, int h)
|
||||
changed_w = snewn(max+1, unsigned int);
|
||||
rowdata = snewn(max+1, int);
|
||||
|
||||
ntries = 0;
|
||||
|
||||
do {
|
||||
ntries++;
|
||||
|
||||
generate(rs, w, h, grid);
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user