router: Fix clamp in meander corner radius calculation.
Fixes https://gitlab.com/kicad/code/kicad/issues/13781
This commit is contained in:
parent
74a242c662
commit
bf1a8f2582
|
@ -211,9 +211,10 @@ int MEANDER_SHAPE::cornerRadius() const
|
|||
int minCr = std::abs( m_baselineOffset );
|
||||
int maxCr = std::min( m_amplitude / 2, spacing() / 2 );
|
||||
|
||||
int cr = std::clamp( optCr, minCr, maxCr );
|
||||
|
||||
return cr;
|
||||
if( maxCr > minCr )
|
||||
return std::clamp( optCr, minCr, maxCr );
|
||||
else
|
||||
return maxCr;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue