diff --git a/src/core/basetypes/MCLock.h b/src/core/basetypes/MCLock.h index 1717a602b..4163c61ac 100644 --- a/src/core/basetypes/MCLock.h +++ b/src/core/basetypes/MCLock.h @@ -9,17 +9,6 @@ #ifndef mailcore2_MCLock_h #define mailcore2_MCLock_h -#if __APPLE__ - -#include - -#define MC_LOCK_TYPE OSSpinLock -#define MC_LOCK_INITIAL_VALUE OS_SPINLOCK_INIT -#define MC_LOCK(l) OSSpinLockLock(l) -#define MC_UNLOCK(l) OSSpinLockUnlock(l) - -#else - #include #define MC_LOCK_TYPE pthread_mutex_t @@ -28,5 +17,3 @@ #define MC_UNLOCK(l) pthread_mutex_unlock(l) #endif - -#endif diff --git a/src/core/basetypes/MCObject.cpp b/src/core/basetypes/MCObject.cpp index 65f675880..4647d941f 100644 --- a/src/core/basetypes/MCObject.cpp +++ b/src/core/basetypes/MCObject.cpp @@ -33,18 +33,12 @@ Object::Object() Object::~Object() { -#ifndef __APPLE__ pthread_mutex_destroy(&mLock); -#endif } void Object::init() { -#if __APPLE__ - mLock = OS_SPINLOCK_INIT; -#else pthread_mutex_init(&mLock, NULL); -#endif mCounter = 1; } diff --git a/src/core/basetypes/MCObject.h b/src/core/basetypes/MCObject.h index 83d6c1a7c..c95da67e6 100644 --- a/src/core/basetypes/MCObject.h +++ b/src/core/basetypes/MCObject.h @@ -57,11 +57,7 @@ namespace mailcore { public: // private private: -#if __APPLE__ - OSSpinLock mLock; -#else pthread_mutex_t mLock; -#endif int mCounter; void init(); static void initObjectConstructors();