mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-04 05:15:21 +00:00
(svn r19619) -Fix (r19618): [desync debug] inserting the "join" pause could cause a crash as some command data was not properly initialised
This commit is contained in:
parent
f14f96d2eb
commit
d2ed777fa5
@ -1147,7 +1147,7 @@ void NetworkGameLoop()
|
|||||||
int ret = sscanf(p + 6, "%x; %x", &next_date, &next_date_fract);
|
int ret = sscanf(p + 6, "%x; %x", &next_date, &next_date_fract);
|
||||||
assert(ret == 2);
|
assert(ret == 2);
|
||||||
DEBUG(net, 0, "injecting pause for join at %08x:%02x; please join when paused", next_date, next_date_fract);
|
DEBUG(net, 0, "injecting pause for join at %08x:%02x; please join when paused", next_date, next_date_fract);
|
||||||
cp = MallocT<CommandPacket>(1);
|
cp = CallocT<CommandPacket>(1);
|
||||||
cp->company = COMPANY_SPECTATOR;
|
cp->company = COMPANY_SPECTATOR;
|
||||||
cp->cmd = CMD_PAUSE;
|
cp->cmd = CMD_PAUSE;
|
||||||
cp->p1 = PM_PAUSED_NORMAL;
|
cp->p1 = PM_PAUSED_NORMAL;
|
||||||
|
Loading…
Reference in New Issue
Block a user