[reSIProcate] segfault in SdpContents::Empty when linking statically

Byron Campen bcampen at estacado.net
Tue Oct 2 10:18:18 CDT 2007


	I don't think anyone has the foggiest of what's going on here. I  
have worked with the static libs on linux a great deal with no  
problems like this, but I'm still on gcc 4.0.2. How are you linking  
against librutil when this problem crops up?

Best regards,
Byron Campen

> Hi
>
> when using resip-1.1 I get a segfault when stopping my application.  
> The crash
> happens in the destruction of "const SdpContents  
> SdpContents::Empty;" (in SdpContents.cxx line 18).
>
> The strange thing is that this only happens when linking statically  
> to libresip.a - when linking
> against a shared library (libresip.so) it works fine.. has anyone  
> seen this before?
>
> The backtrace is below:
>
>
> Program terminated with signal 11, Segmentation fault.
> #0  0xb7e16e3c in std::_List_base<resip::Data,  
> std::allocator<resip::Data> >::_M_clear (this=0x807f020) at
> /usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/ 
> bits/list.tcc:76
> 76                __cur = static_cast<_Node*>(__cur->_M_next);
> (gdb) bt
> #0  0xb7e16e3c in std::_List_base<resip::Data,  
> std::allocator<resip::Data> >::_M_clear (this=0x807f020) at
> /usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/ 
> bits/list.tcc:76
> #1  0xb7e16ee8 in ~_List_base (this=0x807f020) at /usr/lib/gcc/i486- 
> linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_list.h:339
> #2  0xb7e16f37 in ~list (this=0x807f020) at /usr/lib/gcc/i486-linux- 
> gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_list.h:399
> #3  0xb7e16f4f in ~pair (this=0x807effc) at /usr/lib/gcc/i486-linux- 
> gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_pair.h:69
> #4  0xb7e16f9f in __gnu_cxx::new_allocator<std::pair<resip::Data  
> const, std::list<resip::Data, std::allocator<resip::Data> > >  
> >::destroy (this=0xbf930663, __p=0x807effc)
>      at /usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/ 
> 4.1.2/ext/new_allocator.h:107
> #5  0xb7e172ab in __gnu_cxx::hashtable<std::pair<resip::Data const,  
> std::list<resip::Data, std::allocator<resip::Data> > >,  
> resip::Data, __gnu_cxx::hash<resip::Data>,
> std::_Select1st<std::pair<resip::Data const, std::list<resip::Data,  
> std::allocator<resip::Data> > > >, std::equal_to<resip::Data>,  
> std::allocator<std::list<resip::Data,
> std::allocator<resip::Data> > > >::_M_delete_node (this=0xb7fc7fc0,  
> __n=0x807eff8)
>      at /usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/ 
> 4.1.2/ext/hashtable.h:622
> #6  0xb7e17333 in __gnu_cxx::hashtable<std::pair<resip::Data const,  
> std::list<resip::Data, std::allocator<resip::Data> > >,  
> resip::Data, __gnu_cxx::hash<resip::Data>,
> std::_Select1st<std::pair<resip::Data const, std::list<resip::Data,  
> std::allocator<resip::Data> > > >, std::equal_to<resip::Data>,  
> std::allocator<std::list<resip::Data,
> std::allocator<resip::Data> > > >::clear (this=0xb7fc7fc0)
>      at /usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/ 
> 4.1.2/ext/hashtable.h:1086
> #7  0xb7e174e2 in ~hashtable (this=0xb7fc7fc0) at /usr/lib/gcc/i486- 
> linux-gnu/4.1.2/../../../../include/c++/4.1.2/ext/hashtable.h:361
> #8  0xb7e17567 in ~hash_map (this=0xb7fc7fc0) at /usr/lib/gcc/i486- 
> linux-gnu/4.1.2/../../../../include/c++/4.1.2/ext/hash_map:93
> #9  0xb7e1757b in ~AttributeHelper (this=0xb7fc7fc0) at ../../resip/ 
> stack/SdpContents.hxx:20
> #10 0xb7e1ebe5 in ~Session (this=0xb7fc7cd0) at ../../resip/stack/ 
> SdpContents.hxx:47
> #11 0xb7e0ebbd in ~SdpContents (this=0xb7fc7c20) at SdpContents.cxx: 
> 171
> #12 0xb7e0ec22 in __tcf_7 () at SdpContents.cxx:18
> #13 0xb79b65d1 in __cxa_finalize () from /lib/tls/i686/cmov/libc.so.6
> #14 0xb7db4bf3 in __do_global_dtors_aux () from /usr/lib/libkettle.so
> #15 0xb7f095ac in _fini () from /usr/lib/libkettle.so
> #16 0xb7fedede in _dl_fini () from /lib/ld-linux.so.2
> #17 0xb79b63b0 in exit () from /lib/tls/i686/cmov/libc.so.6
> #18 0xb799feb0 in __libc_start_main () from /lib/tls/i686/cmov/ 
> libc.so.6
> #19 0x08048e01 in _start () at ../sysdeps/i386/elf/start.S:119
>
> _______________________________________________
> resiprocate-devel mailing list
> resiprocate-devel at list.resiprocate.org
> https://list.resiprocate.org/mailman/listinfo/resiprocate-devel




More information about the resiprocate-devel mailing list