Loading pcbnew/kicad_plugin.cpp +20 −19 Original line number Original line Diff line number Diff line Loading @@ -181,8 +181,7 @@ void FP_CACHE::Save() // Allow file output stream to go out of scope to close the file stream before // Allow file output stream to go out of scope to close the file stream before // renaming the file. // renaming the file. { { wxLogTrace( traceFootprintLibrary, wxT( "Creating temporary library file %s" ), // wxLogTrace( traceFootprintLibrary, wxT( "Creating temporary library file %s" ), GetChars( tempFileName ) ); GetChars( tempFileName ) ); FILE_OUTPUTFORMATTER formatter( tempFileName ); FILE_OUTPUTFORMATTER formatter( tempFileName ); Loading Loading @@ -218,13 +217,14 @@ void FP_CACHE::Load() wxString fpFileName; wxString fpFileName; wxString wildcard = wxT( "*." ) + KiCadFootprintFileExtension; wxString wildcard = wxT( "*." ) + KiCadFootprintFileExtension; if( !dir.GetFirst( &fpFileName, wildcard, wxDIR_FILES ) ) if( dir.GetFirst( &fpFileName, wildcard, wxDIR_FILES ) ) return; { do do { { // reader now owns fp, will close on exception or return // prepend the libpath into fullPath FILE_LINE_READER reader( fpFileName ); wxFileName fullPath( m_lib_path.GetPath(), fpFileName ); FILE_LINE_READER reader( fullPath.GetFullPath() ); m_owner->m_parser->SetLineReader( &reader ); m_owner->m_parser->SetLineReader( &reader ); Loading @@ -239,6 +239,7 @@ void FP_CACHE::Load() // reload the cache as needed. // reload the cache as needed. m_mod_time = GetLibModificationTime(); m_mod_time = GetLibModificationTime(); } } } void FP_CACHE::Remove( const wxString& aFootprintName ) void FP_CACHE::Remove( const wxString& aFootprintName ) Loading Loading
pcbnew/kicad_plugin.cpp +20 −19 Original line number Original line Diff line number Diff line Loading @@ -181,8 +181,7 @@ void FP_CACHE::Save() // Allow file output stream to go out of scope to close the file stream before // Allow file output stream to go out of scope to close the file stream before // renaming the file. // renaming the file. { { wxLogTrace( traceFootprintLibrary, wxT( "Creating temporary library file %s" ), // wxLogTrace( traceFootprintLibrary, wxT( "Creating temporary library file %s" ), GetChars( tempFileName ) ); GetChars( tempFileName ) ); FILE_OUTPUTFORMATTER formatter( tempFileName ); FILE_OUTPUTFORMATTER formatter( tempFileName ); Loading Loading @@ -218,13 +217,14 @@ void FP_CACHE::Load() wxString fpFileName; wxString fpFileName; wxString wildcard = wxT( "*." ) + KiCadFootprintFileExtension; wxString wildcard = wxT( "*." ) + KiCadFootprintFileExtension; if( !dir.GetFirst( &fpFileName, wildcard, wxDIR_FILES ) ) if( dir.GetFirst( &fpFileName, wildcard, wxDIR_FILES ) ) return; { do do { { // reader now owns fp, will close on exception or return // prepend the libpath into fullPath FILE_LINE_READER reader( fpFileName ); wxFileName fullPath( m_lib_path.GetPath(), fpFileName ); FILE_LINE_READER reader( fullPath.GetFullPath() ); m_owner->m_parser->SetLineReader( &reader ); m_owner->m_parser->SetLineReader( &reader ); Loading @@ -239,6 +239,7 @@ void FP_CACHE::Load() // reload the cache as needed. // reload the cache as needed. m_mod_time = GetLibModificationTime(); m_mod_time = GetLibModificationTime(); } } } void FP_CACHE::Remove( const wxString& aFootprintName ) void FP_CACHE::Remove( const wxString& aFootprintName ) Loading