Fix loading thru-hole pads when drill token is missing.

This commit is contained in:
Alex Shvartzkop 2023-10-14 15:40:08 +03:00
parent 7b94ecdc01
commit f7ed9cc5c7
1 changed files with 5 additions and 0 deletions

View File

@ -4249,6 +4249,11 @@ PAD* PCB_PARSER::parsePAD( FOOTPRINT* aParent )
{
case T_thru_hole:
pad->SetAttribute( PAD_ATTRIB::PTH );
// The drill token is usually missing if 0 drill size is specified.
// Emulate it using 1 nm drill size to avoid errors.
// Drill size cannot be set to 0 in newer versions.
pad->SetDrillSize( VECTOR2I( 1, 1 ) );
break;
case T_smd: