Fixed issues reported by Coverity.
This commit is contained in:
parent
fb29373b4c
commit
094c286024
|
@ -182,7 +182,15 @@ void CONTEXT_MENU::Clear()
|
|||
|
||||
void CONTEXT_MENU::UpdateAll()
|
||||
{
|
||||
m_update_handler();
|
||||
try
|
||||
{
|
||||
m_update_handler();
|
||||
}
|
||||
catch( std::exception& e )
|
||||
{
|
||||
std::cerr << "CONTEXT_MENU error running update handler: " << e.what() << std::endl;
|
||||
}
|
||||
|
||||
updateHotKeys();
|
||||
|
||||
runOnSubmenus( boost::bind( &CONTEXT_MENU::UpdateAll, _1 ) );
|
||||
|
|
|
@ -54,7 +54,17 @@ int PICKER_TOOL::Main( const TOOL_EVENT& aEvent )
|
|||
m_picked = controls->GetCursorPosition();
|
||||
|
||||
if( m_clickHandler )
|
||||
getNext = (*m_clickHandler)( *m_picked );
|
||||
{
|
||||
try
|
||||
{
|
||||
getNext = (*m_clickHandler)( *m_picked );
|
||||
}
|
||||
catch( std::exception& e )
|
||||
{
|
||||
std::cerr << "PICKER_TOOL click handler error: " << e.what() << std::endl;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if( !getNext )
|
||||
break;
|
||||
|
|
|
@ -136,7 +136,7 @@ bool SELECTION_CONDITIONS::sameNetFunc( const SELECTION& aSelection, bool aAllow
|
|||
if( netcode == NETINFO_LIST::UNCONNECTED && !aAllowUnconnected )
|
||||
return false;
|
||||
}
|
||||
else if( netcode != item->GetNetCode() )
|
||||
else if( netcode != current_netcode )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue