mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-18 05:58:19 +00:00
Merge pull request #8831 from furo321/fix-crash-hotreload
Fix `double free or corruption` crash with `hot_reload`
This commit is contained in:
commit
3d6820ab68
|
@ -120,7 +120,7 @@ bool CCharacter::Spawn(CPlayer *pPlayer, vec2 Pos)
|
|||
if(GameServer()->m_apSavedTees[m_pPlayer->GetCid()])
|
||||
{
|
||||
GameServer()->m_apSavedTees[m_pPlayer->GetCid()]->Load(m_pPlayer->GetCharacter(), Team);
|
||||
delete GameServer()->m_apSavedTees[Team];
|
||||
delete GameServer()->m_apSavedTees[m_pPlayer->GetCid()];
|
||||
GameServer()->m_apSavedTees[m_pPlayer->GetCid()] = nullptr;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue