|
View:
New views
17 Messages
—
Rating Filter:
Alert me
|
|
|
Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Segmentation fault on app exit.
log4cxx, apr-1.2.12 and apr-util-1.2.12 had been build from tar file. gcc -v Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.3/specs Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-java-awt=gtk --host=i386-redhat-linux Thread model: posix gcc version 3.4.3 20050227 (Red Hat 3.4.3-22.1) $ uname -a Linux gredhat4 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 i386 GNU/Linux Test app successfully writes one line in log file with code: int main() { PropertyConfigurator::configure(LOG_PROPERTIES_FILE_LOCATION); LoggerPtr LogManager::cplusLoggerPtr = Logger::getLogger("API"); LOG4CXX_INFO(cplusLoggerPtr , "test_info"); return 0; } C++ [C/C++ Local Application] gdb/mi (5/29/08 2:31 PM) (Suspended) Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: Segmentation fault.) 8 apr_atomic_dec32() atomic/unix/apr_atomic.c:310 0xb7d1efba 7 log4cxx::helpers::ObjectImpl::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp:44 0xb7e36da0 6 log4cxx::Logger::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp:62 0xb7e20c5d 5 ~ObjectPtrT() /usr/local/include/log4cxx/helpers/objectptr.h:100 0x080550e3 4 __tcf_1() /home/..project specific... 3 exit() 0x004ce467 2 __libc_start_main() 0x004b8e2d 1 _start() 0x080545ad Any suggestion is welcome... Thanks, Gregory |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Do you have any of the network appenders or possibly the AsyncAppender
configured? I'm guessing this is the same thread shutdown issues I reported on Windows in this thread: http://www.nabble.com/A-few-problems-to-report-to17013024.html The tip should be a bit better, but you might get a delay on shutdown. On Thu, May 29, 2008 at 3:15 PM, GregN <grshore@...> wrote: > > Segmentation fault on app exit. > > log4cxx, apr-1.2.12 and apr-util-1.2.12 had been build from tar file. > > gcc -v > Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.3/specs > Configured with: ../configure --prefix=/usr --mandir=/usr/share/man > --infodir=/usr/share/info --enable-shared --enable-threads=posix > --disable-checking --with-system-zlib --enable-__cxa_atexit > --disable-libunwind-exceptions --enable-java-awt=gtk > --host=i386-redhat-linux > Thread model: posix > gcc version 3.4.3 20050227 (Red Hat 3.4.3-22.1) > > $ uname -a > Linux gredhat4 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 i386 > GNU/Linux > > > Test app successfully writes one line in log file with code: > int main() { > PropertyConfigurator::configure(LOG_PROPERTIES_FILE_LOCATION); > LoggerPtr LogManager::cplusLoggerPtr = Logger::getLogger("API"); > LOG4CXX_INFO(cplusLoggerPtr , "test_info"); > return 0; > } > > > C++ [C/C++ Local Application] > gdb/mi (5/29/08 2:31 PM) (Suspended) > Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: > Segmentation fault.) > 8 apr_atomic_dec32() atomic/unix/apr_atomic.c:310 0xb7d1efba > 7 log4cxx::helpers::ObjectImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp:44 > 0xb7e36da0 > 6 log4cxx::Logger::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp:62 > 0xb7e20c5d > 5 ~ObjectPtrT() /usr/local/include/log4cxx/helpers/objectptr.h:100 > 0x080550e3 > 4 __tcf_1() /home/..project specific... > 3 exit() 0x004ce467 > 2 __libc_start_main() 0x004b8e2d > 1 _start() 0x080545ad > > Any suggestion is welcome... > > Thanks, > Gregory > > -- > View this message in context: http://www.nabble.com/Segmentation-fault-log4cxx-0.10.0-on-app-exit-%28-RH-Linux%29-tp17543738p17543738.html > Sent from the Log4cxx - Users mailing list archive at Nabble.com. > > -- Dale King |
|
|
RE: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)I am facing similar issue with Solaris.
The following link explains my issue. http://mail-archives.apache.org/mod_mbox/logging-log4cxx-user/200804.mbo x/%3cEB4C465FC146B54DAADF4C8C0637BC6202BA6C6D@... %3e Couldn't really get out of this yet. Regards Unni -----Original Message----- From: Dale King [mailto:dalewking@...] Sent: Thursday, May 29, 2008 2:06 PM To: Log4CXX User Subject: Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux) Do you have any of the network appenders or possibly the AsyncAppender configured? I'm guessing this is the same thread shutdown issues I reported on Windows in this thread: http://www.nabble.com/A-few-problems-to-report-to17013024.html The tip should be a bit better, but you might get a delay on shutdown. On Thu, May 29, 2008 at 3:15 PM, GregN <grshore@...> wrote: > > Segmentation fault on app exit. > > log4cxx, apr-1.2.12 and apr-util-1.2.12 had been build from tar file. > > gcc -v > Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.3/specs > Configured with: ../configure --prefix=/usr --mandir=/usr/share/man > --infodir=/usr/share/info --enable-shared --enable-threads=posix > --disable-checking --with-system-zlib --enable-__cxa_atexit > --disable-libunwind-exceptions --enable-java-awt=gtk > --host=i386-redhat-linux > Thread model: posix > gcc version 3.4.3 20050227 (Red Hat 3.4.3-22.1) > > $ uname -a > Linux gredhat4 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 > GNU/Linux > > > Test app successfully writes one line in log file with code: > int main() { > PropertyConfigurator::configure(LOG_PROPERTIES_FILE_LOCATION); > LoggerPtr LogManager::cplusLoggerPtr = Logger::getLogger("API"); > LOG4CXX_INFO(cplusLoggerPtr , "test_info"); > return 0; > } > > > C++ [C/C++ Local Application] > gdb/mi (5/29/08 2:31 PM) (Suspended) > Thread [1] (Suspended: Signal 'SIGSEGV' received. > Segmentation fault.) > 8 apr_atomic_dec32() atomic/unix/apr_atomic.c:310 0xb7d1efba > 7 log4cxx::helpers::ObjectImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp:44 > 0xb7e36da0 > 6 log4cxx::Logger::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp:62 > 0xb7e20c5d > 5 ~ObjectPtrT() /usr/local/include/log4cxx/helpers/objectptr.h:100 > 0x080550e3 > 4 __tcf_1() /home/..project specific... > 3 exit() 0x004ce467 > 2 __libc_start_main() 0x004b8e2d > 1 _start() 0x080545ad > > Any suggestion is welcome... > > Thanks, > Gregory > > -- > View this message in context: RH-Linux%29-tp17543738p17543738.html > Sent from the Log4cxx - Users mailing list archive at Nabble.com. > > -- Dale King |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)I'm not sure how much this helps, but try to use version 1.2.2. If I recall correctly, using the latest version of APR and APR-UTIL gave me issues.
Regards, Omayre
On Thu, May 29, 2008 at 5:18 PM, Unnikrishnan Udinoor <uudinoor@...> wrote: I am facing similar issue with Solaris. |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Only ConsoleAppender and RollingFileAppender are used.
|
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Omayre,
I can't find version 1.2.2 on http://apr.apache.org/download.cgi The 1.2.12 is the latest there. Thanks, Gregory
|
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Greg,
That's true, apache archived that version. It can now be found here: http://archive.apache.org/dist/apr/ Regards, Omayre
On Fri, May 30, 2008 at 9:47 AM, GregN <grshore@...> wrote:
|
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Thanks, Omayre.
I'll try it.
|
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Omayre,
It is the same fault with version 1.2.2... I tryed the same test with log4cpp and it works fine. If I can't get the way to resolve the issue I will use it. Thanks, Gregory
|
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)On May 29, 2008, at 2:15 PM, GregN wrote: > > Segmentation fault on app exit. > > log4cxx, apr-1.2.12 and apr-util-1.2.12 had been build from tar file. > > gcc -v > Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.3/specs > Configured with: ../configure --prefix=/usr --mandir=/usr/share/man > --infodir=/usr/share/info --enable-shared --enable-threads=posix > --disable-checking --with-system-zlib --enable-__cxa_atexit > --disable-libunwind-exceptions --enable-java-awt=gtk > --host=i386-redhat-linux > Thread model: posix > gcc version 3.4.3 20050227 (Red Hat 3.4.3-22.1) > > $ uname -a > Linux gredhat4 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 > i386 > GNU/Linux > > > Test app successfully writes one line in log file with code: > int main() { > PropertyConfigurator::configure(LOG_PROPERTIES_FILE_LOCATION); > LoggerPtr LogManager::cplusLoggerPtr = Logger::getLogger("API"); > LOG4CXX_INFO(cplusLoggerPtr , "test_info"); > return 0; > } > > > C++ [C/C++ Local Application] > gdb/mi (5/29/08 2:31 PM) (Suspended) > Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: > Segmentation fault.) > 8 apr_atomic_dec32() atomic/unix/apr_atomic.c:310 0xb7d1efba > 7 log4cxx::helpers::ObjectImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp: > 44 > 0xb7e36da0 > 6 log4cxx::Logger::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp:62 > 0xb7e20c5d > 5 ~ObjectPtrT() /usr/local/include/log4cxx/helpers/objectptr.h:100 > 0x080550e3 > 4 __tcf_1() /home/..project specific... > 3 exit() 0x004ce467 > 2 __libc_start_main() 0x004b8e2d > 1 _start() 0x080545ad > > Any suggestion is welcome... > > Thanks, > Gregory > APR goes to great length to try to use a platform provided atomic increment and decrement operation to implement apr_atomic_dec32 and apr_atomic_inc32, but contains a fallback implementation that uses APR mutexes to guard the operation. The stack trace suggests that the fallback mechanism was used after APR was terminated APRInitializer::~APRInitializer. Only the fallback implementation is susceptible to crashing if APR is terminated prematurely. It is unclear why was the fallback implementation of apr_atomic_dec32 compiled when building APR. From your platform description, it appears that the inline assembler implementations near the top of atomic/unix/apr_atomic.c should have been compiled. You could probably avoid the Segmentation fault by changing: LoggerPtr LogManager::cplusLoggerPtr = Logger::getLogger("API"); to: LoggerPtr LogManager::cplusLoggerPtr(Logger::getLogger("API")); The problem is that the default constructor for LoggerPtr does not initialize APR and so when things are destructed, APR gets terminated before the LoggerPtr is released. Using the one operation constructor causes APR to be initialized before the LoggerPtr is constructed and so the destruction occurs in the proper order. |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)Unfortunately your suggestion didn't fix the issue. Under debugger the problem happen in apr_atomic.c::apr_atomic_dec32() line:310. It is inside #if APR_HAS_THREADS. I tried to set APR_HAS_THREADS to 0 in include/apr.h but got system lookup error. |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)On May 30, 2008, at 3:16 PM, GregN wrote: > Unfortunately your suggestion didn't fix the issue. > Under debugger the problem happen in apr_atomic.c::apr_atomic_dec32() > line:310. > It is inside #if APR_HAS_THREADS. > I tried to set APR_HAS_THREADS to 0 in include/apr.h but got system > lookup > error. APR_HAS_THREADS ==1 is right and expected, the question is why: #if (defined(__i386__) || defined(__x86_64__)) && defined(__GNUC__) && !defined(USE_GENERAL_ATOMICS) is not true. Forget what I was saying about LoggerPtr. Looking at the stack trace again that isn't the issue. The call to apr_atomic_dec32 that is crashing isn't in the base class for LoggerPtr, it is in the base class (ObjectImpl) for some log4cxx object that is defined as a static. Just not clear which one. A workaround until we can figure out the issue would be to change objectimpl.cpp to avoid apr_atomic_inc32 and apr_atomic_dec32: Index: src/main/cpp/objectimpl.cpp =================================================================== --- src/main/cpp/objectimpl.cpp (revision 654826) +++ src/main/cpp/objectimpl.cpp (working copy) @@ -36,12 +36,12 @@ void ObjectImpl::addRef() const { - apr_atomic_inc32( & ref ); + ref++; } void ObjectImpl::releaseRef() const { - if ( apr_atomic_dec32( & ref ) == 0 ) + if ( --ref == 0 ) { delete this; } |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)I made changes you recommended in src/main/cpp/objectimpl.cpp but it unfortunately didn't help.
It seems that #if statement is true #if (defined(__i386__) || defined(__x86_64__)) && defined(__GNUC__) && !defined(USE_GENERAL_ATOMICS) __i386__ - defined __x86_64__ - NOT defined __GNUC__ - defined USE_GENERAL_ATOMICS - NOT defined (defined(__i386__) || defined(__x86_64__)) && defined(__GNUC__) && !defined(USE_GENERAL_ATOMICS) - defined The stack is: C++ [C/C++ Local Application] gdb/mi (6/4/08 1:46 PM) (Suspended) Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: Segmentation fault.) 27 apr_pool_create_ex() /home/grn/Projects/apr-1.2.12/memory/unix/apr_pools.c:249 0xb7d22fb7 26 Pool() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/pool.cpp:34 0xb7e47db7 25 log4cxx::helpers::IOException::formatMessage() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/exception.cpp:149 0xb7df5176 24 IOException() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/exception.cpp:130 0xb7df65f0 23 log4cxx::helpers::FileOutputStream::close() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/fileoutputstream.cpp:71 0xb7dfef2a 22 log4cxx::rolling::CountingOutputStream::close() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/helpers/objectptr.h:157 0xb7e58102 21 log4cxx::helpers::OutputStreamWriter::close() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/helpers/objectptr.h:157 0xb7e3f278 20 log4cxx::WriterAppender::closeWriter() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/helpers/objectptr.h:157 0xb7e850b1 19 log4cxx::WriterAppender::close() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/writerappender.cpp:143 0xb7e851cf 18 log4cxx::AppenderSkeleton::finalize() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/appenderskeleton.cpp:80 0xb7dc8846 17 ~FileAppender() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/fileappender.cpp:88 0xb7dfafd3 16 ~RollingFileAppenderSkeleton() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/helpers/objectptr.h:100 0xb7dddedc 15 ~RollingFileAppender() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/obsoleterollingfileappender.cpp:87 0xb7e37c55 14 log4cxx::helpers::ObjectImpl::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp:84 0xb7e35e28 13 log4cxx::AppenderSkeleton::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/appenderskeleton.cpp:68 0xb7dc8819 12 ~ObjectPtrT() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/helpers/objectptr.h:100 0xb7dc799c 11 ~AppenderAttachableImpl() /usr/include/c++/3.4.3/bits/stl_construct.h:107 0xb7dc852c 10 log4cxx::helpers::ObjectImpl::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp:84 0xb7e35e28 9 log4cxx::helpers::AppenderAttachableImpl::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/appenderattachableimpl.cpp:41 0xb7dc6bcd 8 ~Logger() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/helpers/objectptr.h:100 0xb7e2065c 7 log4cxx::helpers::ObjectImpl::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp:84 0xb7e35e28 6 log4cxx::Logger::releaseRef() /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp:62 0xb7e1fc65 5 ~ObjectPtrT() /usr/local/include/log4cxx/helpers/objectptr.h:100 0x080550e3 4 __tcf_1() /home/grn/Projects/C++/..project related.. 0x08083e91 3 exit() 0x004ce467 2 __libc_start_main() 0x004b8e2d 1 _start() 0x080545ad |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)On Jun 4, 2008, at 1:14 PM, GregN wrote: > > I made changes you recommended in src/main/cpp/objectimpl.cpp but it > unfortunately didn't help. > > It seems that #if statement is true > > #if (defined(__i386__) || defined(__x86_64__)) && defined(__GNUC__) > && !defined(USE_GENERAL_ATOMICS) > > __i386__ - defined > __x86_64__ - NOT defined > __GNUC__ - defined > USE_GENERAL_ATOMICS - NOT defined > (defined(__i386__) || defined(__x86_64__)) && defined(__GNUC__) && > !defined(USE_GENERAL_ATOMICS) - defined > The previous stack trace suggested that the expression was false. > The stack is: > C++ [C/C++ Local Application] > gdb/mi (6/4/08 1:46 PM) (Suspended) > Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: > Segmentation fault.) > 27 apr_pool_create_ex() > /home/grn/Projects/apr-1.2.12/memory/unix/apr_pools.c:249 0xb7d22fb7 > 26 Pool() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/pool.cpp:34 > 0xb7e47db7 > 25 log4cxx::helpers::IOException::formatMessage() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/exception.cpp: > 149 > 0xb7df5176 > 24 IOException() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/exception.cpp: > 130 > 0xb7df65f0 > 23 log4cxx::helpers::FileOutputStream::close() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > fileoutputstream.cpp:71 > 0xb7dfef2a > 22 log4cxx::rolling::CountingOutputStream::close() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/ > helpers/objectptr.h:157 > 0xb7e58102 > 21 log4cxx::helpers::OutputStreamWriter::close() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/ > helpers/objectptr.h:157 > 0xb7e3f278 > 20 log4cxx::WriterAppender::closeWriter() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/ > helpers/objectptr.h:157 > 0xb7e850b1 > 19 log4cxx::WriterAppender::close() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > writerappender.cpp:143 > 0xb7e851cf > 18 log4cxx::AppenderSkeleton::finalize() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > appenderskeleton.cpp:80 > 0xb7dc8846 > 17 ~FileAppender() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > fileappender.cpp:88 > 0xb7dfafd3 > 16 ~RollingFileAppenderSkeleton() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/ > helpers/objectptr.h:100 > 0xb7dddedc > 15 ~RollingFileAppender() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > obsoleterollingfileappender.cpp:87 > 0xb7e37c55 > 14 log4cxx::helpers::ObjectImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp: > 84 > 0xb7e35e28 > 13 log4cxx::AppenderSkeleton::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > appenderskeleton.cpp:68 > 0xb7dc8819 > 12 ~ObjectPtrT() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/ > helpers/objectptr.h:100 > 0xb7dc799c > 11 ~AppenderAttachableImpl() > /usr/include/c++/3.4.3/bits/stl_construct.h:107 0xb7dc852c > 10 log4cxx::helpers::ObjectImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp: > 84 > 0xb7e35e28 > 9 log4cxx::helpers::AppenderAttachableImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/ > appenderattachableimpl.cpp:41 > 0xb7dc6bcd > 8 ~Logger() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/include/log4cxx/ > helpers/objectptr.h:100 > 0xb7e2065c > 7 log4cxx::helpers::ObjectImpl::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/objectimpl.cpp: > 84 > 0xb7e35e28 > 6 log4cxx::Logger::releaseRef() > /home/grn/Projects/apache-log4cxx-0.10.0/src/main/cpp/logger.cpp:62 > 0xb7e1fc65 > 5 ~ObjectPtrT() /usr/local/include/log4cxx/helpers/objectptr.h:100 > 0x080550e3 > 4 __tcf_1() /home/grn/Projects/C++/..project related.. 0x08083e91 > 3 exit() 0x004ce467 > 2 __libc_start_main() 0x004b8e2d > 1 _start() 0x080545ad > This stack trace is different since it doesn't die in apr_atomic_dec32, but the underlying problem is still the same, APR is terminated prematurely during destruction of static variables. I have spent a little time trying to reproduce this issue, but haven't succeeded yet. As a work around until a resolution, you could try commenting out the apr_terminate() call in src/main/cpp/aprinitializer.cpp. |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)>As a work around until a resolution, you could try commenting out the
>apr_terminate() call in src/main/cpp/aprinitializer.cpp. It works with this change. Let me know if I can help you to fix the problem. THanks.. |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)On Jun 6, 2008, at 10:07 AM, GregN wrote: > >> As a work around until a resolution, you could try commenting out the >> apr_terminate() call in src/main/cpp/aprinitializer.cpp. > > It works with this change. > Let me know if I can help you to fix the problem. > THanks.. > Without the fix, does "make check" successfully run the unit tests. What specific RedHat are you running, is it a RHEL or a Fedora and what version? I don't have access to RHEL, but do have CentOS VM's that I can fire up. Could you see if using a current gcc would eliminate the problem. There have been reported bugs with static deinitialization in gcc (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24472 ), I believe there have been others, but couldn't find them in the gcc Bugzilla. |
|
|
Re: Segmentation fault log4cxx 0.10.0 on app exit ( RH Linux)>Without the fix, does "make check" successfully run the unit tests. Seems all tests passed with SUCCESS. I saved the log if you want it. >What specific RedHat are you running... It is Enterprise RH (probably 4.3) [grn@gredhat4 ~]$ uname -a Linux gredhat4 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 i386 GNU/Linux [grn@gredhat4 ~]$ Linux gredhat4 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 i386 GNU/Linux >Could you see if using a current gcc would eliminate the problem. Sorry, I can't switch to latest gcc at this moment. |
| Free embeddable forum powered by Nabble | Forum Help |