# HG changeset patch # User Darkvater # Date 1163286487 0 # Node ID 99ff52c14896c2dc05bfa5be945bbd5195ccaf87 # Parent 69195f96a23a538c6cdd994cb1601958e736c07c (svn r7131) -Fix (r7126) which fixes (r2817) the activating of a function call that was 1. never executed before that and even if it would, it 2. could never be executed because if it did OpenTTD would crash diff -r 69195f96a23a -r 99ff52c14896 players.c --- a/players.c Sat Nov 11 10:12:00 2006 +0000 +++ b/players.c Sat Nov 11 23:08:07 2006 +0000 @@ -860,11 +860,18 @@ if (_local_player != _network_playas) { assert(_local_player == PLAYER_SPECTATOR && _network_playas == p->index); _local_player = p->index; - DoCommandP(0, (_patches.autorenew << 15 ) | (_patches.autorenew_months << 16) | 4, _patches.autorenew_money, NULL, CMD_SET_AUTOREPLACE); - MarkWholeScreenDirty(); } + /* Now that we have a new player, broadcast its autorenew settings to + * all clients so everything is in sync */ + DoCommand(0, + (_patches.autorenew << 15 ) | (_patches.autorenew_months << 16) | 4, + _patches.autorenew_money, + DC_EXEC, + CMD_SET_AUTOREPLACE + ); + #ifdef ENABLE_NETWORK if (_network_server) { /* XXX - UGLY! p2 (pid) is mis-used to fetch the client-id, done at