Hi!
I just compiled mutella-0.4.3rc1on SunOS 5.8 using gcc
2.95.3. As the docs state, it does not run very
stable. I used gdb to collect information about 3
crashes that happened randomly, mostly while waiting
and watching "info loop".
Seems mostly to be due to corrupted data... Don't
understand nothing of STL though...
Here's what I copy-pasted from my GDB-Terminal:
Crash #1 -- SIGSEGV
(gdb) bt
#0 0x163de0 in list<PriorityPacket,
allocator<PriorityPacket> >::erase (
this=0x2d1c60, __position={_M_node = 0x299398})
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_list.h:387
#1 0x163528 in list<PriorityPacket,
allocator<PriorityPacket> >::pop_front (
this=0x2d1c60)
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_list.h:399
#2 0xc0b10 in MGnuNode::FlushSendBuffer
(this=0x2d00c8) at gnunode.cpp:1137
#3 0xc0c28 in MGnuNode::OnSend (this=0x2d00c8,
nErrorCode=150)
at gnunode.cpp:1175
#4 0xb0a5c in MAsyncSocket::Heartbeat (nSleep=100) at
asyncsocket.cpp:781
#5 0xb0e48 in MGnutellaThread::run (this=0x19f270) at
controller.cpp:93
#6 0x158398 in MThreadPrivate::internalRun
(that=0x19f270) at mthread_p.h:954
#7 0xae228 in start_thread (t=0x19f270) at
mthread_p.h:1207
(gdb) list stl_list.h:387
382 void push_back() {insert(end());}
383
384 iterator erase(iterator __position) {
385 _Node* __next_node = (_Node*)
(__position._M_node->_M_next);
386 _Node* __prev_node = (_Node*)
(__position._M_node->_M_prev);
387 __prev_node->_M_next = __next_node;
388 __next_node->_M_prev = __prev_node;
389 destroy(&__position._M_node->_M_data);
390 _M_put_node(__position._M_node);
391 return iterator(__next_node);
(gdb) list stl_list.h:399
394 void clear() { _Base::clear(); }
395
396 void resize(size_type __new_size, const _Tp&
__x);
397 void resize(size_type __new_size) {
resize(__new_size, _Tp()); }
398
399 void pop_front() { erase(begin()); }
400 void pop_back() {
401 iterator __tmp = end();
402 erase(--__tmp);
403 }
(gdb) list gnunode.cpp:1137
1132
1133 return;
1134 }
1135 // Delete packet once sent
1136 m_PacketListLength[i] -=
itPacket->Length;
1137 m_PacketList[i].pop_front();
1138
1139 m_nStatisticsSec[NR_PACKET_OUT]++;
1140 }
1141 ASSERT(m_PacketList[0].empty());
(gdb) frame 2
#2 0xc0b10 in MGnuNode::FlushSendBuffer
(this=0x2d00c8) at gnunode.cpp:1137
1137 m_PacketList[i].pop_front();
(gdb) print i
$1 = 3
(gdb) print m_PacketList[i]
$2 =
{<_List_base<PriorityPacket,allocator<PriorityPacket>
>> =
{<_List_alloc_base<PriorityPacket,allocator<PriorityPacket>,>>
= {_M_node = 0x350640}, }, }
(gdb) print m_PacketListLength[i]
$3 = 155
(gdb) print itPacket
$4 = {_M_node = 0x299398}
(gdb) frame 0
#0 0x163de0 in list<PriorityPacket,
allocator<PriorityPacket> >::erase (
this=0x2d1c60, __position={_M_node = 0x299398})
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_list.h:387
387 __prev_node->_M_next = __next_node;
(gdb) print __position
$5 = {_M_node = 0x299398}
(gdb) print __position._M_node
$6 = (_List_node<PriorityPacket> *) 0x299398
(gdb) print *__position._M_node
$7 = {_M_next = 0x2993e8, _M_prev = 0x0, _M_data =
{Length = 0,
Packet = 0x1a1ec0 ":
ŕ[˘ś{ű(\021M\013\206i\037Ű\200\001\004\013"}}
Crash #2 -- bus error
(gdb) bt
#0 0xff0c2784 in _free_unlocked ()
#1 0xff0c273c in free ()
#2 0xff204378 in __builtin_vec_delete (ptr=0x69745469)
at /usr/gnu/src/gcc/gcc-2.95.3/gcc/cp/new2.cc:62
#3 0x162f7c in PriorityPacket::~PriorityPacket
(this=0x29a348, __in_chrg=2)
at gnunode.h:74
#4 0x1633c8 in destroy__H1Z14PriorityPacket_PX01_v
(__pointer=0x29a348)
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_construct.h:43
#5 0x162b08 in _List_base<PriorityPacket,
allocator<PriorityPacket> >::clear (
this=0x330ec8)
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_list.h:239
#6 0x163c00 in _List_base<PriorityPacket,
allocator<PriorityPacket> >::~_List_base
(this=0x330ec8, __in_chrg=0)
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_list.h:192
#7 0x163278 in list<PriorityPacket,
allocator<PriorityPacket> >::~list (
this=0x330ec8, __in_chrg=0)
at
/usr/gnu/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/../../../../include/g++-3/stl_list.h:437
#8 0xbc7d8 in MGnuNode::~MGnuNode (this=0x32f330,
__in_chrg=3)
at gnunode.cpp:214
---Type <return> to continue, or q <return> to quit---
#9 0xd46a4 in MGnuDirector::ManageConnects
(this=0x1a4d88,
nTimeStamp=1042031285) at gnudirector.cpp:1945
#10 0xd2cc4 in MGnuDirector::OnTimer (this=0x1a4d88,
nTimeStamp=1042031285)
at gnudirector.cpp:1628
#11 0xb0e90 in MGnutellaThread::run (this=0x19f270) at
controller.cpp:102
#12 0x158398 in MThreadPrivate::internalRun
(that=0x19f270) at mthread_p.h:954
#13 0xae228 in start_thread (t=0x19f270) at
mthread_p.h:1207
(gdb) list gnunode.h:74
69 Packet = new BYTE[nLen];
70 memcpy(Packet, pData, nLen);
71 }
72 ~PriorityPacket() {
73 if (Packet)
74 delete [] Packet;
75 }
76 PriorityPacket(const PriorityPacket&
orig) : Packet(orig.Packet), Length(orig.Length) {
77
const_cast<PriorityPacket*>(&orig)->Packet = NULL;
78
const_cast<PriorityPacket*>(&orig)->Length = 0;
(gdb) frame 3
#3 0x162f7c in PriorityPacket::~PriorityPacket
(this=0x29a348, __in_chrg=2)
at gnunode.h:74
74 delete [] Packet;
(gdb) print Packet
$1 = (u_char *) 0x69745469 <Address 0x69745469 out of
bounds>
(gdb) print *this
$2 = {Length = 1937072749,
Packet = 0x69745469 <Address 0x69745469 out of bounds>}
(gdb) frame 8
#8 0xbc7d8 in MGnuNode::~MGnuNode (this=0x32f330,
__in_chrg=3)
at gnunode.cpp:214
214 delete m_pBuff;
(gdb) print m_PacketList+3
$12 = (list<PriorityPacket,allocator<PriorityPacket> >
*) 0x330ec8
Crash #3 -- SIGSEGV
Program received signal SIGSEGV, Segmentation fault.
0xff0c1f74 in realfree ()
(gdb) bt
#0 0xff0c1f74 in realfree ()
#1 0xff0c2880 in cleanfree ()
#2 0xff0c19b4 in _malloc_unlocked ()
#3 0xff0c18a8 in malloc ()
#4 0xff2042c4 in __builtin_new (sz=7112)
at /usr/gnu/src/gcc/gcc-2.95.3/gcc/cp/new1.cc:84
#5 0xcd9b0 in MGnuDirector::AddNode (this=0x1a4d88,
ipHost={S_un_b = {
s_b1 = 210 'Ň', s_b2 = 50 '2', s_b3 = 100 'd',
s_b4 = 112 'p'},
S_un_w = {s_w1 = 53810, s_w2 = 25712}, S_ip = {a
= 210 'Ň', b = 50 '2',
c = 100 'd', d = 112 'p'}, S_addr =
3526517872}, Port=6346,
bForceV4=false) at gnudirector.cpp:681
#6 0xd4d54 in MGnuDirector::AddConnect (this=0x1a4d88,
bSuperpeer=true)
at gnudirector.cpp:2041
#7 0xd4b48 in MGnuDirector::ManageConnects
(this=0x1a4d88,
nTimeStamp=1042036180) at gnudirector.cpp:2016
#8 0xd2cc4 in MGnuDirector::OnTimer (this=0x1a4d88,
nTimeStamp=1042036180)
at gnudirector.cpp:1628
#9 0xb0e90 in MGnutellaThread::run (this=0x19f270) at
controller.cpp:102
#10 0x158398 in MThreadPrivate::internalRun
(that=0x19f270) at mthread_p.h:954
#11 0xae228 in start_thread (t=0x19f270) at
mthread_p.h:1207
------------
Hope this helps. If you need more information feel
free to mail me at 'dvdkhlng AT gmx DOT de'.
cu
David Kuehling