feat(Core/Threading): replace ace threading (#4821)

This commit is contained in:
Kargatum
2021-04-17 00:45:29 +07:00
committed by GitHub
parent b9e84d8278
commit b2861be1cd
50 changed files with 300 additions and 342 deletions

View File

@@ -199,13 +199,13 @@ MapEntry const* InstanceSave::GetMapEntry()
void InstanceSave::AddPlayer(uint32 guidLow)
{
ACORE_GUARD(ACE_Thread_Mutex, _lock);
std::lock_guard<std::mutex> guard(_lock);
m_playerList.push_back(guidLow);
}
bool InstanceSave::RemovePlayer(uint32 guidLow, InstanceSaveManager* ism)
{
ACORE_GUARD(ACE_Thread_Mutex, _lock);
std::lock_guard<std::mutex> guard(_lock);
m_playerList.remove(guidLow);
// ism passed as an argument to avoid calling via singleton (might result in a deadlock)