Fix typos that produce segfaults.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/16696
This commit is contained in:
Jeff Young 2024-01-21 22:25:57 +00:00
parent 1981997ee2
commit 2627c99654
1 changed files with 2 additions and 2 deletions

View File

@ -1487,10 +1487,10 @@ void PAD::ImportSettingsFrom( const PAD& aMasterPad )
// The pad orientation, for historical reasons is the pad rotation + parent rotation.
EDA_ANGLE pad_rot = aMasterPad.GetOrientation();
if( aMasterPad.GetParent() )
if( aMasterPad.GetParentFootprint() )
pad_rot -= aMasterPad.GetParentFootprint()->GetOrientation();
if( GetParent() )
if( GetParentFootprint() )
pad_rot += GetParentFootprint()->GetOrientation();
SetOrientation( pad_rot );