Project

General

Profile

Bug #2343 ยป 0091-map_generate_fair_islands-Fix-set-but-unused-warning.patch

Marko Lindqvist, 10/06/2026 07:22 PM

View differences:

server/generator/mapgen.c
int playermass, islandmass1 , islandmass2, islandmass3;
int min_island_size = wld.map.server.tinyisles ? 1 : 2;
int players_per_island = 1;
int teams_num = 0, team_players_num = 0, single_players_num = 0;
int teams_num = 0, team_players_num = 0;
int i, iter = CLIP(1, 100000 / map_num_tiles(), 10);
bool done = FALSE;
#if !defined(FREECIV_NDEBUG) || defined(FREECIV_DEBUG)
int single_players_num = 0;
#endif
teams_iterate(pteam) {
i = player_list_size(team_members(pteam));
fc_assert(0 < i);
if (i == 1) {
single_players_num++;
} else {
if (i != 1) {
teams_num++;
team_players_num += i;
#if !defined(FREECIV_NDEBUG) || defined(FREECIV_DEBUG)
} else {
single_players_num++;
#endif
}
} teams_iterate_end;
fc_assert(team_players_num + single_players_num == player_count());
/* Take in account the 'startpos' setting. */
    (1-1/1)