Modeling - BRepFilletAPI_MakeFillet Segfault with two curves and rim #532

Added null checks for TopoDS_Face in ChFi3d_Builder_2 and BRepAdaptor_Surface.
Added tests to check for crash.
This commit is contained in:
Dmitrii Kulikov
2025-05-15 19:35:52 +01:00
committed by GitHub
parent ebc3885799
commit a56d85bf15
3 changed files with 111 additions and 9 deletions
@@ -70,6 +70,11 @@ Handle(Adaptor3d_Surface) BRepAdaptor_Surface::ShallowCopy() const
void BRepAdaptor_Surface::Initialize(const TopoDS_Face& F, const Standard_Boolean Restriction)
{
if (F.IsNull())
{
return;
}
myFace = F;
TopLoc_Location L;
const Handle(Geom_Surface)& aSurface = BRep_Tool::Surface(F, L);