Hi
I have the same problem and I could not solve. I have installed the version
apache-log4cxx-0.10.0. apr-1.3.6 and apr-util-1.3.8. in a Red Hat 5 x64
I tried with the patch 596934 and does not work.
When the program ends gives an exception
terminate called after throwing an instance of
'log4cxx::helpers::MutexException'
what(): Mutex exception: stat = 22
./tester.sh: line 71: 17226 Aborted ./tester
Rhosyn wrote:
The attach patch fixes a thread safety issue we found with ObjectPtrBase
when we ported our application to a 64 bit platform.
It will only work if you are using a version of apr with
apr_atomic_xchgptr()
Cheers
______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit
http://www.messagelabs.com/email
______________________________________________________________________
--- /home/rhosyn/SVN/oakx41/main/thirdparty/log4cxx/_build/app.host/app/apache-log4cxx-0.10.0/src/main/cpp/objectptr.cpp 2008-03-31 23:34:09.000000000 +0100
+++ /home/rhosyn/SVN/oakx41/main/thirdparty/log4cxx/_build/app.app/app/apache-log4cxx-0.10.0/src/main/cpp/objectptr.cpp 2009-01-07 15:39:03.000000000 +0000
@@ -36,12 +36,7 @@
void* ObjectPtrBase::exchange(void** destination, void* newValue) {
#if _WIN32 && (!defined(_MSC_VER) || _MSC_VER >= 1300)
return InterlockedExchangePointer(destination, newValue);
-#elif APR_SIZEOF_VOIDP == 4
- return (void*) apr_atomic_xchg32((volatile apr_uint32_t*) destination,
- (apr_uint32_t) newValue);
#else
- void* oldValue = *destination;
- *destination = newValue;
- return oldValue;
+ apr_atomic_xchgptr((volatile void**)destination, newValue);
#endif
}