mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-30 09:03:47 +00:00
feat(Core/Threading): replace ace threading (#4821)
This commit is contained in:
@@ -78,9 +78,6 @@
|
||||
|
||||
#include "Threading/LockedQueue.h"
|
||||
#include "Threading/Threading.h"
|
||||
|
||||
#include <ace/RW_Thread_Mutex.h>
|
||||
#include <ace/Thread_Mutex.h>
|
||||
#include <ace/Stack_Trace.h>
|
||||
|
||||
#if AC_PLATFORM == AC_PLATFORM_WINDOWS
|
||||
@@ -124,8 +121,6 @@ inline float finiteAlways(float f) { return isfinite(f) ? f : 0.0f; }
|
||||
|
||||
inline bool myisfinite(float f) { return isfinite(f) && !isnan(f); }
|
||||
|
||||
#define atol(a) strtoul( a, nullptr, 10)
|
||||
|
||||
#define STRINGIZE(a) #a
|
||||
|
||||
#define MAX_NETCLIENT_PACKET_SIZE (32767 - 1) // Client hardcap: int16 with trailing zero space otherwise crash on memory free
|
||||
@@ -187,22 +182,6 @@ typedef std::vector<std::string> StringVector;
|
||||
|
||||
#define MAX_QUERY_LEN 32*1024
|
||||
|
||||
#define ACORE_GUARD(MUTEX, LOCK) \
|
||||
ACE_Guard< MUTEX > ACORE_GUARD_OBJECT (LOCK); \
|
||||
if (ACORE_GUARD_OBJECT.locked() == 0) ASSERT(false);
|
||||
|
||||
//! For proper implementation of multiple-read, single-write pattern, use
|
||||
//! ACE_RW_Mutex as underlying @MUTEX
|
||||
# define ACORE_WRITE_GUARD(MUTEX, LOCK) \
|
||||
ACE_Write_Guard< MUTEX > ACORE_GUARD_OBJECT (LOCK); \
|
||||
if (ACORE_GUARD_OBJECT.locked() == 0) ASSERT(false);
|
||||
|
||||
//! For proper implementation of multiple-read, single-write pattern, use
|
||||
//! ACE_RW_Mutex as underlying @MUTEX
|
||||
# define ACORE_READ_GUARD(MUTEX, LOCK) \
|
||||
ACE_Read_Guard< MUTEX > ACORE_GUARD_OBJECT (LOCK); \
|
||||
if (ACORE_GUARD_OBJECT.locked() == 0) ASSERT(false);
|
||||
|
||||
namespace acore
|
||||
{
|
||||
template<class ArgumentType, class ResultType>
|
||||
|
||||
Reference in New Issue
Block a user