diff --git a/cvpcb/autosel.cpp b/cvpcb/autosel.cpp index 34d5cf1b80..5075e321f0 100644 --- a/cvpcb/autosel.cpp +++ b/cvpcb/autosel.cpp @@ -72,7 +72,17 @@ void CVPCB_MAINFRAME::AssocieModule( wxCommandEvent& event ) for( ii = 0; ii < m_AliasLibNames.GetCount(); ii++ ) { fn = m_AliasLibNames[ii]; - fn.SetExt( FootprintAliasFileExtension ); + //msg.Printf( _( "Library: %s." ), + // GetChars( fn.GetFullName() ) ); + //wxMessageBox( msg, titleLibLoadError, wxOK | wxICON_ERROR ); + if( !fn.HasExt() ) { + fn.SetExt( FootprintAliasFileExtension ); + // above fails if filename have more than one point + } + else + { + fn.SetExt( fn.GetExt() + wxT( "." ) + FootprintAliasFileExtension ); + } tmp = wxGetApp().FindLibraryPath( fn ); if( !tmp )