svn trunk segmentation faults

Mark Clarkson mark.clarkson at smorg.co.uk
Sun Jan 13 07:36:31 PST 2008


Hi,
My app no longer works with the latest svn trunk and seems to break when
it loads an html list box. In the debug build I get the following
asserts, showing just the first assert each time I run my app then the
app segfaults:

[Debug] 15:19:21: ../include/wx/html/htmltag.h(135): assert
"m_hasEnding" failed in GetEndIter2().

[Debug] 15:28:35: ../src/common/stringimpl.cpp(187): assert
"wxAssertFailure" failed in wxStringImpl(): first must be before last

These were from the GTK build. The windows build segfaults as well.

I got the following backtrace from gnome one time:

[New Thread 0xb72f5a50 (LWP 1797)]
[New Thread 0xb6bd6b90 (LWP 1814)]
0xb7702321 in waitpid () from /lib/libpthread.so.0
#0  0xb7702321 in waitpid () from /lib/libpthread.so.0
#1  0xb79196a4 in g_spawn_sync () from /usr/lib/libglib-2.0.so.0
#2  0xb79199bc in g_spawn_command_line_sync ()
from /usr/lib/libglib-2.0.so.0
#3  0xb7fb0268 in ?? ()
from /usr/lib/gtk-2.0/modules/libgnomebreakpad.so
#4  <signal handler called>
#5  0x08075047 in
wxStringOperationsUtf8::IncIter<wxStringImpl::const_iterator>
    (i=@0xbfd7b9f4) at ../include/wx/stringops.h:79
#6  0x08075123 in
wxStringOperationsUtf8::DiffIters<wxStringImpl::const_iterator>
(i1={m_ptr = 0x1132a60c <Address 0x1132a60c out of bounds>}, i2=
      {m_ptr = 0x8a0f000 <Address 0x8a0f000 out of bounds>})
    at ../include/wx/stringops.h:135
#7  0x0807515e in wxString::const_iterator::operator- (this=0xbfd7ba3c, 
    i=@0xbfd7ba24) at ../include/wx/string.h:692
#8  0x080751a3 in wxString::length (this=0xbfd7ba8c)
    at ../include/wx/string.h:1036
#9  0x0813f182 in wxHtmlTag::GetParamAsColour (this=0x898b6c8, 
    par=@0xbfd7bb94, clr=0xbfd7bb64) at ../src/html/htmltag.cpp:473
#10 0x0811b3a8 in wxHTML_Handler_FONT::HandleTag (this=0xb6a004a8, 
    tag=@0x898b6c8) at ../src/html/m_fonts.cpp:45
#11 0x0813b6d7 in wxHtmlParser::AddTag (this=0xb6a00a60, tag=@0x898b6c8)
    at ../src/html/htmlpars.cpp:317
#12 0x0813b596 in wxHtmlParser::DoParsing (this=0xb6a00a60, 
    begin_pos_=@0xbfd7be68, end_pos=@0xbfd7be50)
    at ../src/html/htmlpars.cpp:302
#13 0x0813b74e in wxHtmlParser::AddTag (this=0xb6a00a60, tag=@0x891fa90)
    at ../src/html/htmlpars.cpp:324
#14 0x0813b596 in wxHtmlParser::DoParsing (this=0xb6a00a60, 
    begin_pos_=@0xbfd7c008, end_pos=@0xbfd7bff0)
    at ../src/html/htmlpars.cpp:302
#15 0x0813b74e in wxHtmlParser::AddTag (this=0xb6a00a60, tag=@0x8989000)
    at ../src/html/htmlpars.cpp:324
#16 0x0813b596 in wxHtmlParser::DoParsing (this=0xb6a00a60, 
    begin_pos_=@0xbfd7c17c, end_pos=@0xbfd7c164)
    at ../src/html/htmlpars.cpp:302
#17 0x08119edf in wxHtmlTagHandler::ParseInner (this=0xb6a02040, 
    tag=@0x8959dd8) at ../include/wx/html/htmlpars.h:247
#18 0x0812ba38 in wxHTML_Handler_TABLE::HandleTag (this=0xb6a02040, 
    tag=@0x8959dd8) at ../src/html/m_tables.cpp:713
#19 0x0813b6d7 in wxHtmlParser::AddTag (this=0xb6a00a60, tag=@0x8959dd8)
    at ../src/html/htmlpars.cpp:317
#20 0x0813b596 in wxHtmlParser::DoParsing (this=0xb6a00a60, 
    begin_pos_=@0xbfd7c50c, end_pos=@0xbfd7c4f4)
    at ../src/html/htmlpars.cpp:302
#21 0x0813b802 in wxHtmlParser::DoParsing (this=0xb6a00a60)
    at ../src/html/htmlpars.cpp:261
#22 0x0813b8c8 in wxHtmlParser::Parse (this=0xb6a00a60,
source=@0xbfd7c5a0)
    at ../src/html/htmlpars.cpp:106
#23 0x08130887 in wxHtmlListBox::CacheItem (this=0x88ca010, n=2)
    at ../src/generic/htmllbox.cpp:305
#24 0x08130be9 in wxHtmlListBox::OnMeasureItem (this=0x88ca010, n=2)
    at ../src/generic/htmllbox.cpp:378
#25 0x082d5b0d in wxVListBox::OnGetRowHeight (this=0x88ca010, line=2)
    at ../src/generic/vlbox.cpp:349
#26 0x0807b6ff in wxVarVScrollHelper::OnGetUnitSize (this=0x88ca170,
n=2)
    at ../include/wx/vscroll.h:344
#27 0x082d8c6f in wxVarScrollHelperBase::RefreshUnits (this=0x88ca170,
from=0, 
    to=8) at ../src/generic/vscroll.cpp:504
#28 0x08131fd4 in wxVarVScrollHelper::RefreshRows (this=0x88ca170,
from=0, 
    to=8) at ../include/wx/vscroll.h:325
#29 0x0812f936 in wxHtmlListBox::RefreshRows (this=0x88ca010, from=0,
to=8)
    at ../src/generic/htmllbox.cpp:337
#30 0x082d86b8 in wxVarVScrollLegacyAdaptor::RefreshLines
(this=0x88ca170, 
    from=0, to=8) at ../src/generic/vscroll.cpp:950
#31 0x080677ee in MainFrame::OnHtmlListBoxUpdate (this=0x8894a08)
    at mainframe.cpp:1197
#32 0x0807e896 in ProcessCmd::do_hlistsetitem_entry (this=0x88866e8)
    at processcmd.cpp:556
#33 0x0807fc54 in ProcessCmd::Doit (this=0x88866e8, cmd=0x8979308)
    at processcmd.cpp:872
#34 0x080682d3 in MainFrame::OnRead (this=0x8894a08, event=@0x89788e0)
    at mainframe.cpp:754
#35 0x0834d5b1 in wxAppConsoleBase::HandleEvent (this=0x85d4728, 
    handler=0x8894a08, func=0x806824a
<MainFrame::OnRead(wxCommandEvent&)>, 
    event=@0x89788e0) at ../src/common/appbase.cpp:417
#36 0x08401484 in wxEvtHandler::ProcessEventIfMatches
(entry=@0x85adfc8, 
    handler=0x8894a08, event=@0x89788e0) at ../src/common/event.cpp:1222
#37 0x08403378 in wxEventHashTable::HandleEvent (this=0x85adf04, 
    event=@0x89788e0, self=0x8894a08) at ../src/common/event.cpp:901
#38 0x084034c6 in wxEvtHandler::ProcessEvent (this=0x8894a08,
event=@0x89788e0)
    at ../src/common/event.cpp:1284
#39 0x08401ff4 in wxEvtHandler::ProcessPendingEvents (this=0x8894a08)
    at ../src/common/event.cpp:1184
#40 0x0834f6dd in wxAppConsoleBase::ProcessPendingEvents
(this=0x85d4728)
    at ../src/common/appbase.cpp:372
#41 0x0820cbbf in wxAppBase::ProcessIdle (this=0x85d4728)
    at ../src/common/appcmn.cpp:355
#42 0x0819f91b in wxApp::DoIdle (this=0x85d4728)
at ../src/gtk/app.cpp:193
#43 0x0819f9fb in wxapp_idle_callback () at ../src/gtk/app.cpp:165
#44 0xb78e6661 in ?? () from /usr/lib/libglib-2.0.so.0
#45 0x00000000 in ?? ()

This part of the application code has worked fine for the last year,
although I'm not saying it's not my fault!

Cheers
Mark.




More information about the wx-users mailing list