diff -Nur -X/mnt/data/freeciv-dev/freeciv/diff_ignore freeciv/server/citytools.c codeciv/server/citytools.c --- freeciv/server/citytools.c Fri Jul 20 12:45:22 2001 +++ codeciv/server/citytools.c Fri Jul 20 14:05:06 2001 @@ -715,8 +715,8 @@ Only relevant if we are transfering to another player. */ if (pplayer != pvictim) { unit_list_iterate(map_get_tile(x, y)->units, vunit) { - /* Dont transfer units already owned by new city-owner --wegge */ - if (unit_owner(vunit) == pvictim && pcity) { + /* Don't transfer units already owned by new city-owner --wegge */ + if (unit_owner(vunit) == pvictim) { transfer_unit(vunit, pcity, verbose); wipe_unit_safe(vunit, &myiter); unit_list_unlink(units, vunit); @@ -863,7 +863,7 @@ if (resolve_stack) { no_units = unit_list_size(&old_city_units); if (no_units > 0) { - resolve_list = fc_malloc(no_units * sizeof(struct map_position)); + resolve_list = fc_malloc((no_units + 1) * sizeof(struct map_position)); if (resolve_list) { i = 0; unit_list_iterate(old_city_units, punit) { @@ -871,6 +871,8 @@ resolve_list[i].y = punit->y; i++; } unit_list_iterate_end; + resolve_list[i].x = pcity->x; + resolve_list[i].y = pcity->y; assert(i == no_units); } } @@ -884,7 +886,7 @@ reset_move_costs(pcity->x, pcity->y); if (resolve_stack && (no_units > 0) && resolve_list) { - for (i = 0; i < no_units ; i++) + for (i = 0; i < no_units+1 ; i++) resolve_unit_stack(resolve_list[i].x, resolve_list[i].y, transfer_unit_verbose); free(resolve_list); diff -Nur -X/mnt/data/freeciv-dev/freeciv/diff_ignore freeciv/server/plrhand.c codeciv/server/plrhand.c --- freeciv/server/plrhand.c Fri Jul 20 12:45:22 2001 +++ codeciv/server/plrhand.c Fri Jul 20 13:42:49 2001 @@ -1697,6 +1697,12 @@ unit_list_iterate(pplayer->units, punit) resolve_unit_stack(punit->x, punit->y, 0); unit_list_iterate_end; + city_list_iterate(pplayer->cities, pcity) { + resolve_unit_stack(pcity->x, pcity->y, 0); + } city_list_iterate_end; + city_list_iterate(cplayer->cities, pcity) { + resolve_unit_stack(pcity->x, pcity->y, 0); + } city_list_iterate_end; notify_player(0,