From 781093a65dd7459ff7a8d1f87b7ec774f7ecb525 Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Sat, 2 Oct 2021 15:13:03 +0300 Subject: [PATCH 10/10] Fix revealing trade partner to destination owner when trade route established If the owner of the destination city already knew the tile where the source city is, but only from time before the city was founded, the source city was not revealed. This even lead to client crashes as traderoutes there were between owned city and NULL. See osdn #42968 Signed-off-by: Marko Lindqvist --- server/citytools.c | 2 +- server/unithand.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/server/citytools.c b/server/citytools.c index 991625f786..e864ae0dd7 100644 --- a/server/citytools.c +++ b/server/citytools.c @@ -988,7 +988,7 @@ static void reestablish_city_trade_routes(struct city *pcity) /* Give the new owner infos about the city which has a trade route * with the transferred city. */ - reality_check_city(city_owner(pcity), ptrade_city->tile); + map_show_tile(city_owner(pcity), ptrade_city->tile); update_dumb_city(city_owner(pcity), ptrade_city); send_city_info(city_owner(pcity), ptrade_city); } trade_routes_iterate_end; diff --git a/server/unithand.c b/server/unithand.c index aabea56bcb..3032b1a6e1 100644 --- a/server/unithand.c +++ b/server/unithand.c @@ -3246,9 +3246,9 @@ static bool do_unit_establish_trade(struct player *pplayer, /* Notify each player about the other cities so that they know about * its size for the trade calculation. */ if (pplayer != partner_player) { - reality_check_city(partner_player, city_tile(pcity_homecity)); + map_show_tile(partner_player, city_tile(pcity_homecity)); send_city_info(partner_player, pcity_homecity); - reality_check_city(pplayer, city_tile(pcity_dest)); + map_show_tile(pplayer, city_tile(pcity_dest)); send_city_info(pplayer, pcity_dest); } -- 2.33.0