From d409a3642d6ee33b61945b9e002c7e5c9fb747f8 Mon Sep 17 00:00:00 2001 From: dpasukhi Date: Tue, 28 Jan 2025 15:49:11 +0000 Subject: [PATCH] Modeling - Add warning for incomplete wire detection in WireFromList #299 --- src/BRepFill/BRepFill_Filling.cxx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/BRepFill/BRepFill_Filling.cxx b/src/BRepFill/BRepFill_Filling.cxx index 420d9dc5e4..4ba10915fd 100644 --- a/src/BRepFill/BRepFill_Filling.cxx +++ b/src/BRepFill/BRepFill_Filling.cxx @@ -119,6 +119,12 @@ static TopoDS_Wire WireFromList(TopTools_ListOfShape& Edges) break; } } + if (!itl.More()) + { + Message::SendWarning() << "Warning: WireFromList: can't find the next edge. The wire is not " + "complete, some edges are lost."; + break; + } BB.Add(aWire, anEdge); Edges.Remove(itl); }