Bounds checking (KICAD-8V9)

This commit is contained in:
Jeff Young 2025-07-04 16:39:35 -06:00
parent 6a11c7d87a
commit 4f6de4c5a1

View File

@ -66,7 +66,7 @@ wxString FOOTPRINTS_LISTBOX::GetSelectedFootprint()
wxString footprintName; wxString footprintName;
int ii = GetFirstSelected(); int ii = GetFirstSelected();
if( ii >= 0 ) if( ii >= 0 && ii < m_footprintList.size() )
{ {
wxString msg = m_footprintList[ii]; wxString msg = m_footprintList[ii];
msg.Trim( true ); msg.Trim( true );