From a4929f9c27e900db17ddd8ac345b974b5de3581f Mon Sep 17 00:00:00 2001 From: Roberto Fernandez Bautista Date: Sat, 2 Mar 2024 19:09:33 +0100 Subject: [PATCH] Step exporter: handle circles correctly Fixes https://gitlab.com/kicad/code/kicad/-/issues/17137 --- pcbnew/exporters/step/step_pcb_model.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pcbnew/exporters/step/step_pcb_model.cpp b/pcbnew/exporters/step/step_pcb_model.cpp index 5da97c6409..a1252744e1 100644 --- a/pcbnew/exporters/step/step_pcb_model.cpp +++ b/pcbnew/exporters/step/step_pcb_model.cpp @@ -769,7 +769,7 @@ bool STEP_PCB_MODEL::MakeShapes( std::vector& aShapes, const SHAPE int nextShape = aChain.NextShape( i ); // If nextShape points to the end, then we have a circle. - if( nextShape != aChain.PointCount() - 1 ) + if( nextShape != -1 ) i = nextShape; } }