Segfault calling wxAuiToolBar::GetToolBarFits().
|Reported by:||stambaughw||Owned by:|
I get the following segfault:
0x6a1a67a6 in GetToolFitsByIndex (tool_idx=11, this=0x3fb134b8)
1785 cli_w -= m_overflowSizerItem->GetSize().x;
when calling wxAuiToolBar::GetToolBarFits() when the wxAUI_TB_OVERFLOW flag is not set in the style argument when creating the tool bar. Obviously the problem is m_overflowSizeItem is NULL. My guess is the best place to fix this is within GetToolFitsByIndex rather than GetToolBarFits but I will leave that up to your expertise. Also, you may want to look at all of the other places m_overflowSizeItem is used in auibar.cpp. I don't think this is the only place where this issue can occur. I checked trunk and this problem still exists.
The only reason I found this problem may be the result of another issue with the tool bar overflow behavior. I was under the impression that the overflow control would only be displayed when the tool bar does not fit in it's parent window but my experience (at least on Windows) is that it is always shown so I was attempting to set the overflow control visibility when the window is resized or the tool bar is moved or resized.
Change History (6)
comment:1 Changed 12 months ago by vadz
- Milestone 3.0.1 deleted
- Status changed from new to infoneeded_new