diff options
author | Tofu Linden <tofu.linden@lindenlab.com> | 2010-05-01 06:47:55 +0100 |
---|---|---|
committer | Tofu Linden <tofu.linden@lindenlab.com> | 2010-05-01 06:47:55 +0100 |
commit | f92d7f282954d5f4601178603aa715ae74287957 (patch) | |
tree | 85c7018fac0dc3151ff9e22c3e6248468781ebe1 /indra/llcommon/llerror.cpp | |
parent | b0fa1e011f14356b3634f39d32f43e244b6f1298 (diff) | |
parent | 1b827077717483d59d1d16ec4203ae9fb8199c8f (diff) |
merge from viewer-trunk
Diffstat (limited to 'indra/llcommon/llerror.cpp')
-rw-r--r-- | indra/llcommon/llerror.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/indra/llcommon/llerror.cpp b/indra/llcommon/llerror.cpp index bd334a6654..41ff5849f4 100644 --- a/indra/llcommon/llerror.cpp +++ b/indra/llcommon/llerror.cpp @@ -1225,17 +1225,32 @@ namespace LLError char** LLCallStacks::sBuffer = NULL ; S32 LLCallStacks::sIndex = 0 ; +#define SINGLE_THREADED 1 + class CallStacksLogLock { public: CallStacksLogLock(); ~CallStacksLogLock(); + +#if SINGLE_THREADED + bool ok() const { return true; } +#else bool ok() const { return mOK; } private: bool mLocked; bool mOK; +#endif }; +#if SINGLE_THREADED + CallStacksLogLock::CallStacksLogLock() + { + } + CallStacksLogLock::~CallStacksLogLock() + { + } +#else CallStacksLogLock::CallStacksLogLock() : mLocked(false), mOK(false) { @@ -1271,6 +1286,7 @@ namespace LLError apr_thread_mutex_unlock(gCallStacksLogMutexp); } } +#endif //static void LLCallStacks::push(const char* function, const int line) |