diff --git a/common/drawframe.cpp b/common/drawframe.cpp index 152152fe1a..31048df82f 100644 --- a/common/drawframe.cpp +++ b/common/drawframe.cpp @@ -1023,7 +1023,6 @@ wxPoint EDA_DRAW_FRAME::GetCrossHairPosition( bool aInvertY ) const if( IsGalCanvasActive() ) { VECTOR2I cursor = GetGalCanvas()->GetViewControls()->GetCursorPosition(); - cursor = GetGalCanvas()->GetGAL()->GetGridPoint( cursor ); return wxPoint( cursor.x, cursor.y ); } diff --git a/include/wxPcbStruct.h b/include/wxPcbStruct.h index be47c3bd22..1298f96e1f 100644 --- a/include/wxPcbStruct.h +++ b/include/wxPcbStruct.h @@ -216,8 +216,6 @@ public: bool m_show_microwave_tools; bool m_show_layer_manager_tools; - -public: PCB_EDIT_FRAME( wxWindow* father, const wxString& title, const wxPoint& pos, const wxSize& size, long style = KICAD_DEFAULT_DRAWFRAME_STYLE ); diff --git a/pcbnew/ratsnest_data.cpp b/pcbnew/ratsnest_data.cpp index 5bff81fe4f..4242ea6bf1 100644 --- a/pcbnew/ratsnest_data.cpp +++ b/pcbnew/ratsnest_data.cpp @@ -1024,7 +1024,7 @@ void RN_DATA::updateNet( int aNetCode ) { assert( aNetCode < (int) m_nets.size() ); - if( aNetCode < 1 ) + if( aNetCode < 1 || aNetCode > m_nets.size() ) return; m_nets[aNetCode].ClearSimple();