Fix not handled exceptions.
This commit is contained in:
parent
8098db2a20
commit
a855c9a40c
|
@ -281,8 +281,16 @@ static void idf_export_footprint( BOARD* aPcb, FOOTPRINT* aFootprint, IDF3_BOARD
|
||||||
|
|
||||||
if( aPcb->GetProject() )
|
if( aPcb->GetProject() )
|
||||||
{
|
{
|
||||||
const FP_LIB_TABLE_ROW* fpRow =
|
const FP_LIB_TABLE_ROW* fpRow = nullptr;
|
||||||
aPcb->GetProject()->PcbFootprintLibs()->FindRow( libraryName, false );
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
fpRow = aPcb->GetProject()->PcbFootprintLibs()->FindRow( libraryName, false );
|
||||||
|
}
|
||||||
|
catch( ... )
|
||||||
|
{
|
||||||
|
// Not found: do nothing
|
||||||
|
}
|
||||||
|
|
||||||
if( fpRow )
|
if( fpRow )
|
||||||
footprintBasePath = fpRow->GetFullURI( true );
|
footprintBasePath = fpRow->GetFullURI( true );
|
||||||
|
|
|
@ -999,8 +999,16 @@ void EXPORTER_PCB_VRML::ExportVrmlFootprint( FOOTPRINT* aFootprint, std::ostream
|
||||||
|
|
||||||
if( m_board->GetProject() )
|
if( m_board->GetProject() )
|
||||||
{
|
{
|
||||||
const FP_LIB_TABLE_ROW* fpRow =
|
const FP_LIB_TABLE_ROW* fpRow = nullptr;
|
||||||
m_board->GetProject()->PcbFootprintLibs()->FindRow( libraryName, false );
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
fpRow = m_board->GetProject()->PcbFootprintLibs()->FindRow( libraryName, false );
|
||||||
|
}
|
||||||
|
catch( ... )
|
||||||
|
{
|
||||||
|
// Not found: do nothing
|
||||||
|
}
|
||||||
|
|
||||||
if( fpRow )
|
if( fpRow )
|
||||||
footprintBasePath = fpRow->GetFullURI( true );
|
footprintBasePath = fpRow->GetFullURI( true );
|
||||||
|
|
Loading…
Reference in New Issue