Make sure spice command doesn't assert

Fixes https://gitlab.com/kicad/code/kicad/issues/4328
This commit is contained in:
Seth Hillbrand 2021-10-22 16:49:34 -07:00
parent febfe39cc4
commit 927b633c01
1 changed files with 4 additions and 1 deletions

View File

@ -300,7 +300,10 @@ void NETLIST_DIALOG::OnRunExternSpiceCommand( wxCommandEvent& event )
if( m_Parent->ReadyToNetlist( _( "Simulator requires a fully annotated schematic." ) ) )
{
m_Parent->WriteNetListFile( NET_TYPE_SPICE, fn.GetFullPath(), netlist_opt, nullptr );
wxExecute( commandLine, wxEXEC_ASYNC );
commandLine.Trim( true ).Trim( false );
if( !commandLine.IsEmpty() )
wxExecute( commandLine, wxEXEC_ASYNC );
}
}