Avoid crashed in eeschema after selecting/deselecting and reselecting highlight tool or delete tool
It was due to use of items in std::deque without testing if these items exist.
This commit is contained in:
parent
da645c5d16
commit
e800bc5ffe
|
@ -452,10 +452,10 @@ void EDA_DRAW_FRAME::PushTool( const std::string& actionName )
|
|||
|
||||
void EDA_DRAW_FRAME::PopTool()
|
||||
{
|
||||
if( m_toolStack.size() > 1 )
|
||||
{
|
||||
m_toolStack.pop_back();
|
||||
|
||||
if( !m_toolStack.empty() )
|
||||
{
|
||||
TOOL_ACTION* action = m_toolManager->GetActionManager()->FindAction( m_toolStack.back() );
|
||||
|
||||
if( action )
|
||||
|
|
Loading…
Reference in New Issue