Fix errant debug message

__WXDEBUG__ is only for internal WX debugging and is always enabled even
on release builds because it is defined to be 0, 1 or 2.  Use DEBUG to
limit to debug builds

Fixes https://gitlab.com/kicad/code/kicad/issues/9392
This commit is contained in:
Seth Hillbrand 2021-10-13 09:15:48 -07:00
parent 95ec23247c
commit 07b9e2ee51
1 changed files with 2 additions and 2 deletions

View File

@ -1229,14 +1229,14 @@ void PAD::ViewGetLayers( int aLayers[], int& aCount ) const
aLayers[aCount++] = each_layer;
}
#ifdef __WXDEBUG__
#ifdef DEBUG
if( aCount == 0 ) // Should not occur
{
wxString msg;
msg.Printf( wxT( "footprint %s, pad %s: could not find valid layer for pad" ),
GetParent() ? GetParent()->GetReference() : "<null>",
GetNumber().IsEmpty() ? "(unnumbered)" : GetNumber() );
wxLogWarning( msg );
wxLogDebug( msg );
}
#endif
}