Prevent crash trying to load missing spice lib

(cherry picked from commit 4fe7c7a902)
This commit is contained in:
Marek Roszko 2023-09-05 21:13:16 -04:00 committed by Mark Roszko
parent 955313e97d
commit 95e6be0e81
No known key found for this signature in database
1 changed files with 3 additions and 0 deletions

View File

@ -186,6 +186,9 @@ bool DIALOG_SIM_MODEL<T_symbol, T_field>::TransferDataToWindow()
{
m_libraryPathText->ChangeValue( libraryFilename );
m_curModelType = SIM_MODEL::ReadTypeFromFields( m_fields, &reporter );
// load library will mangle the set reporter
m_libraryModelsMgr.SetReporter( &reporter );
m_libraryModelsMgr.CreateModel( nullptr, m_sortedPartPins, m_fields );
m_modelNameChoice->Append( _( "<unknown>" ) );