Loading include/cutils/threads.h +10 −12 Original line number Diff line number Diff line Loading @@ -29,7 +29,7 @@ extern "C" { /***********************************************************************/ /***********************************************************************/ #ifdef HAVE_PTHREADS #if !defined(_WIN32) #include <pthread.h> Loading @@ -42,7 +42,7 @@ typedef struct { #define THREAD_STORE_INITIALIZER { PTHREAD_MUTEX_INITIALIZER, 0, 0 } #elif defined HAVE_WIN32_THREADS #else // !defined(_WIN32) #include <windows.h> Loading @@ -56,9 +56,7 @@ typedef struct { #define THREAD_STORE_INITIALIZER { 0, 0, 0, {0, 0, 0, 0, 0, 0} } #else # error "no thread_store_t implementation for your platform !!" #endif #endif // !defined(_WIN32) typedef void (*thread_store_destruct_t)(void* value); Loading @@ -76,7 +74,7 @@ extern void thread_store_set(thread_store_t* store, /***********************************************************************/ /***********************************************************************/ #ifdef HAVE_PTHREADS #if !defined(_WIN32) typedef pthread_mutex_t mutex_t; Loading @@ -98,9 +96,9 @@ static __inline__ void mutex_destroy(mutex_t* lock) { pthread_mutex_destroy(lock); } #endif #ifdef HAVE_WIN32_THREADS #else // !defined(_WIN32) typedef struct { int init; CRITICAL_SECTION lock[1]; Loading Loading @@ -137,7 +135,7 @@ static __inline__ void mutex_destroy(mutex_t* lock) DeleteCriticalSection(lock->lock); } } #endif #endif // !defined(_WIN32) #ifdef __cplusplus } Loading include/log/log.h +2 −4 Original line number Diff line number Diff line Loading @@ -28,14 +28,12 @@ #ifndef _LIBS_LOG_LOG_H #define _LIBS_LOG_LOG_H #include <sys/types.h> #ifdef HAVE_PTHREADS #include <pthread.h> #endif #include <stdarg.h> #include <stdio.h> #include <sys/types.h> #include <time.h> #include <unistd.h> #include <log/logd.h> #include <log/uio.h> Loading include/log/logd.h +8 −7 Original line number Diff line number Diff line Loading @@ -23,16 +23,17 @@ #include <android/log.h> /* the rest is only used internally by the system */ #include <time.h> #include <stdio.h> #include <unistd.h> #include <stdint.h> #include <sys/types.h> #ifdef HAVE_PTHREADS #if !defined(_WIN32) #include <pthread.h> #endif #include <log/uio.h> #include <stdarg.h> #include <stdint.h> #include <stdio.h> #include <sys/types.h> #include <time.h> #include <unistd.h> #include <log/uio.h> #ifdef __cplusplus extern "C" { Loading include/utils/AndroidThreads.h +1 −1 Original line number Diff line number Diff line Loading @@ -20,7 +20,7 @@ #include <stdint.h> #include <sys/types.h> #if defined(HAVE_PTHREADS) #if !defined(_WIN32) # include <pthread.h> #endif Loading include/utils/Condition.h +4 −4 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ #include <sys/types.h> #include <time.h> #if defined(HAVE_PTHREADS) #if !defined(_WIN32) # include <pthread.h> #endif Loading Loading @@ -74,7 +74,7 @@ public: void broadcast(); private: #if defined(HAVE_PTHREADS) #if !defined(_WIN32) pthread_cond_t mCond; #else void* mState; Loading @@ -83,7 +83,7 @@ private: // --------------------------------------------------------------------------- #if defined(HAVE_PTHREADS) #if !defined(_WIN32) inline Condition::Condition() { pthread_cond_init(&mCond, NULL); Loading Loading @@ -149,7 +149,7 @@ inline void Condition::broadcast() { pthread_cond_broadcast(&mCond); } #endif // HAVE_PTHREADS #endif // !defined(_WIN32) // --------------------------------------------------------------------------- }; // namespace android Loading Loading
include/cutils/threads.h +10 −12 Original line number Diff line number Diff line Loading @@ -29,7 +29,7 @@ extern "C" { /***********************************************************************/ /***********************************************************************/ #ifdef HAVE_PTHREADS #if !defined(_WIN32) #include <pthread.h> Loading @@ -42,7 +42,7 @@ typedef struct { #define THREAD_STORE_INITIALIZER { PTHREAD_MUTEX_INITIALIZER, 0, 0 } #elif defined HAVE_WIN32_THREADS #else // !defined(_WIN32) #include <windows.h> Loading @@ -56,9 +56,7 @@ typedef struct { #define THREAD_STORE_INITIALIZER { 0, 0, 0, {0, 0, 0, 0, 0, 0} } #else # error "no thread_store_t implementation for your platform !!" #endif #endif // !defined(_WIN32) typedef void (*thread_store_destruct_t)(void* value); Loading @@ -76,7 +74,7 @@ extern void thread_store_set(thread_store_t* store, /***********************************************************************/ /***********************************************************************/ #ifdef HAVE_PTHREADS #if !defined(_WIN32) typedef pthread_mutex_t mutex_t; Loading @@ -98,9 +96,9 @@ static __inline__ void mutex_destroy(mutex_t* lock) { pthread_mutex_destroy(lock); } #endif #ifdef HAVE_WIN32_THREADS #else // !defined(_WIN32) typedef struct { int init; CRITICAL_SECTION lock[1]; Loading Loading @@ -137,7 +135,7 @@ static __inline__ void mutex_destroy(mutex_t* lock) DeleteCriticalSection(lock->lock); } } #endif #endif // !defined(_WIN32) #ifdef __cplusplus } Loading
include/log/log.h +2 −4 Original line number Diff line number Diff line Loading @@ -28,14 +28,12 @@ #ifndef _LIBS_LOG_LOG_H #define _LIBS_LOG_LOG_H #include <sys/types.h> #ifdef HAVE_PTHREADS #include <pthread.h> #endif #include <stdarg.h> #include <stdio.h> #include <sys/types.h> #include <time.h> #include <unistd.h> #include <log/logd.h> #include <log/uio.h> Loading
include/log/logd.h +8 −7 Original line number Diff line number Diff line Loading @@ -23,16 +23,17 @@ #include <android/log.h> /* the rest is only used internally by the system */ #include <time.h> #include <stdio.h> #include <unistd.h> #include <stdint.h> #include <sys/types.h> #ifdef HAVE_PTHREADS #if !defined(_WIN32) #include <pthread.h> #endif #include <log/uio.h> #include <stdarg.h> #include <stdint.h> #include <stdio.h> #include <sys/types.h> #include <time.h> #include <unistd.h> #include <log/uio.h> #ifdef __cplusplus extern "C" { Loading
include/utils/AndroidThreads.h +1 −1 Original line number Diff line number Diff line Loading @@ -20,7 +20,7 @@ #include <stdint.h> #include <sys/types.h> #if defined(HAVE_PTHREADS) #if !defined(_WIN32) # include <pthread.h> #endif Loading
include/utils/Condition.h +4 −4 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ #include <sys/types.h> #include <time.h> #if defined(HAVE_PTHREADS) #if !defined(_WIN32) # include <pthread.h> #endif Loading Loading @@ -74,7 +74,7 @@ public: void broadcast(); private: #if defined(HAVE_PTHREADS) #if !defined(_WIN32) pthread_cond_t mCond; #else void* mState; Loading @@ -83,7 +83,7 @@ private: // --------------------------------------------------------------------------- #if defined(HAVE_PTHREADS) #if !defined(_WIN32) inline Condition::Condition() { pthread_cond_init(&mCond, NULL); Loading Loading @@ -149,7 +149,7 @@ inline void Condition::broadcast() { pthread_cond_broadcast(&mCond); } #endif // HAVE_PTHREADS #endif // !defined(_WIN32) // --------------------------------------------------------------------------- }; // namespace android Loading