Miscellaneous const fixes

These are cases where -Wcast-qual complained and the only change needed
was to add or remove a "const" (or sometimes an entire cast).
This commit is contained in:
Ben Harris
2023-02-18 23:14:12 +00:00
parent 3c3468355f
commit 26c7f3aa28
5 changed files with 9 additions and 9 deletions

View File

@ -1031,8 +1031,8 @@ static void connect_numbers(game_state *state)
static int compare_heads(const void *a, const void *b)
{
struct head_meta *ha = (struct head_meta *)a;
struct head_meta *hb = (struct head_meta *)b;
const struct head_meta *ha = (const struct head_meta *)a;
const struct head_meta *hb = (const struct head_meta *)b;
/* Heads with preferred colours first... */
if (ha->preference && !hb->preference) return -1;
@ -2421,7 +2421,7 @@ static void process_desc(char *id)
thegame.free_params(p);
}
int main(int argc, const char *argv[])
int main(int argc, char *argv[])
{
char *id = NULL, *desc, *aux = NULL;
const char *err;