mirror of
https://github.com/rehlds/rehlds.git
synced 2025-01-04 02:55:50 +03:00
Fixed crash when player was kicked in ClientPutInServer
This commit is contained in:
parent
36a87f58c2
commit
9836aef6bb
@ -1463,6 +1463,12 @@ void SV_WriteSpawn(sizebuf_t *msg)
|
|||||||
gGlobalVariables.time = g_psv.time;
|
gGlobalVariables.time = g_psv.time;
|
||||||
gEntityInterface.pfnClientPutInServer(sv_player);
|
gEntityInterface.pfnClientPutInServer(sv_player);
|
||||||
g_psv.state = ss_active;
|
g_psv.state = ss_active;
|
||||||
|
|
||||||
|
#ifdef REHLDS_FIXES
|
||||||
|
// Client was kicked in ClientPutInServer
|
||||||
|
if (!host_client->connected)
|
||||||
|
return;
|
||||||
|
#endif // REHLDS_FIXES
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef REHLDS_FIXES
|
#ifndef REHLDS_FIXES
|
||||||
@ -1680,6 +1686,13 @@ void SV_Spawn_f(void)
|
|||||||
{
|
{
|
||||||
SZ_Write(&msg, g_psv.signon.data, g_psv.signon.cursize);
|
SZ_Write(&msg, g_psv.signon.data, g_psv.signon.cursize);
|
||||||
SV_WriteSpawn(&msg);
|
SV_WriteSpawn(&msg);
|
||||||
|
|
||||||
|
#ifdef REHLDS_FIXES
|
||||||
|
// Client was kicked in ClientPutInServer
|
||||||
|
if (!host_client->connected)
|
||||||
|
return;
|
||||||
|
#endif // REHLDS_FIXES
|
||||||
|
|
||||||
SV_WriteVoiceCodec(&msg);
|
SV_WriteVoiceCodec(&msg);
|
||||||
Netchan_CreateFragments(TRUE, &host_client->netchan, &msg);
|
Netchan_CreateFragments(TRUE, &host_client->netchan, &msg);
|
||||||
Netchan_FragSend(&host_client->netchan);
|
Netchan_FragSend(&host_client->netchan);
|
||||||
|
Loading…
Reference in New Issue
Block a user