improved OSX compatibility and fixed possible crash in debug mode in Pcbnew

This commit is contained in:
charras 2009-07-20 05:25:12 +00:00
parent 1868bb8e3c
commit 4c001cd4ed
1 changed files with 2 additions and 0 deletions

View File

@ -827,10 +827,12 @@ NETINFO_ITEM* BOARD::FindNet( int anetcode ) const
// zero is reserved for "no connection" and is not used. // zero is reserved for "no connection" and is not used.
// NULL is returned for non valid netcodes // NULL is returned for non valid netcodes
NETINFO_ITEM* item = m_NetInfo->GetNetItem( anetcode ); NETINFO_ITEM* item = m_NetInfo->GetNetItem( anetcode );
#if defined(DEBUG)
if ( item ) // item can be NULL if not valid if ( item ) // item can be NULL if not valid
{ {
wxASSERT( anetcode == item->GetNet() ); wxASSERT( anetcode == item->GetNet() );
} }
#endif
return item; return item;
} }