[Debtags-devel] Segfaults when using debtags
Benjamin Mesing
bensmail at gmx.net
Sun Aug 7 13:48:26 UTC 2005
Hello,
I've updated to the latest debtags/apt/tagcoll versions. Now I get a
segfault when trying to recompile the old version of packagesearch (as
1.3.1):
This is the code where it happens - on the last line the project
crashes. (The call of SingleSimpleDebtags::getInstance() returns the
DebtagsSimple
Tagcoll::InputMerger<int, string> merger;
Tagcoll::TagcollBuilder collBuilder(*_pHandleMaker);
// TODO workaround for libdebtags bug
SingleSimpleDebtags::getInstance()->tagDB().outputSystem(collBuilder);
// now sent the collection to the InputMerger
collBuilder.collection().output(merger);
Backtrace:
#0 0x40d6533e in __gnu_cxx::__pool<true>::_M_reclaim_block () from /usr/lib/libstdc++.so.6
#1 0x400c8262 in __gnu_cxx::__mt_alloc<std::_Rb_tree_node<std::pair<std::string const, int> >, __gnu_cxx::__common_pool_policy<__gnu_cxx::__pool, true> >::deallocate () from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#2 0x400ca8d1 in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#3 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#4 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#5 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#6 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#7 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#8 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#9 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#10 0x400ca8ef in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::_M_erase ()
from /usr/lib/libapt-pkg-libc6.3-6.so.3.10
#11 0x414d907f in std::_Rb_tree<std::string, std::pair<std::string const, int>, std::_Select1st<std::pair<std::string const, int> >, std::less<std::string>, std::allocator<std::pair<std::string const, int> > >::clear (this=0xbffff434) at stl_tree.h:847
#12 0x414d8f82 in ~_Rb_tree (this=0xbffff434) at stl_tree.h:748
#13 0x414d8b7f in ~map (this=0xbffff434) at TagCollection.h:54
---Type <return> to continue, or q <return> to quit---
#14 0x414d8509 in ~TagContainer (this=0xbffff434) at TagCollection.h:56
#15 0x414d8126 in ~TagCollection (this=0xbffff430) at TagCollection.h:80
#16 0x414d7a9e in NPlugin::DebtagsPluginContainer::updateDebtags (this=0x9d6efd8) at debtagsplugincontainer.cpp:299
In my current development version I also get a crash, but it looks like
this:
0x400abbe0 in std::string::compare () from /usr/lib/libstdc++.so.5
(gdb) bt
#0 0x400abbe0 in std::string::compare () from /usr/lib/libstdc++.so.5
#1 0x08097c7a in operator< <char, std::char_traits<char>, std::allocator<char> > (__lhs=@0xbffff2b0,
__rhs=@0x67615447) at basic_string.h:948
#2 0x080962ac in std::less<std::string>::operator() (this=0xbffff300, __x=@0xbffff2b0, __y=@0x67615447)
at stl_function.h:197
#3 0x080923c6 in std::_Rb_tree<std::string, std::string, std::_Identity<std::string>, std::less<std::string>, std::allocator<std::string> >::insert_unique (this=0xbffff2f8, __v=@0xbffff2b0) at stl_tree.h:1042
#4 0x413ae353 in Tagcoll::TDBFile::deserialize_stringset () from plugins/libdebtagsplugin.so
#5 0x413ae5ec in Tagcoll::TDBFile::getStringSet () from plugins/libdebtagsplugin.so
#6 0x41331911 in Debtags::Vocabulary::getFacets () from plugins/libdebtagsplugin.so
#7 0x413061c0 in NPlugin::DebtagsPluginContainer::updateVocabulary (this=0x9d90c38, informPlugins=false)
at debtagsplugincontainer.cpp:229
Where debtagsplugincontainer.cpp:229 contains the line:
_facets = SingleSimpleDebtags::getInstance()->vocabulary().getFacets();
Note that version 1.3.1 links against /usr/lib/libstdc++.so.6 and my
development version against /usr/lib/libstdc++.so.5. I have no idea
why...
Greetings Ben (who starts to hate ABI changes)
More information about the Debtags-devel
mailing list