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

@@ -2251,7 +2251,7 @@ void World::Update(uint32 diff)
// so we don't have to do it in every packet that modifies auctions
AsyncAuctionListingMgr::SetAuctionListingAllowed(false);
{
ACORE_GUARD(ACE_Thread_Mutex, AsyncAuctionListingMgr::GetLock());
std::lock_guard<std::mutex> guard(AsyncAuctionListingMgr::GetLock());
// pussywizard: handle auctions when the timer has passed
if (m_timers[WUPDATE_AUCTIONS].Passed())

View File

@@ -465,7 +465,7 @@ private:
std::string _realmName;
// CLI command holder to be thread safe
ACE_Based::LockedQueue<CliCommandHolder*, ACE_Thread_Mutex> cliCmdQueue;
LockedQueue<CliCommandHolder*> cliCmdQueue;
// next daily quests and random bg reset time
time_t m_NextDailyQuestReset;
@@ -480,7 +480,7 @@ private:
// sessions that are added async
void AddSession_(WorldSession* s);
ACE_Based::LockedQueue<WorldSession*, ACE_Thread_Mutex> addSessQueue;
LockedQueue<WorldSession*> addSessQueue;
// used versions
std::string m_DBVersion;