mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-07 18:30:55 +03:00
SALOME_37951_SIGSEGV_MakeVertexInsideFace Fixed exceptions with loading null curve and using out of range index. By K.Leontev.
This commit is contained in:
parent
2261172c3b
commit
c84a97e12f
@ -76,7 +76,10 @@ void BRepAdaptor_Curve2d::Initialize(const TopoDS_Edge& E,
|
|||||||
myFace = F;
|
myFace = F;
|
||||||
Standard_Real pf,pl;
|
Standard_Real pf,pl;
|
||||||
const Handle(Geom2d_Curve) PC = BRep_Tool::CurveOnSurface(E,F,pf,pl);
|
const Handle(Geom2d_Curve) PC = BRep_Tool::CurveOnSurface(E,F,pf,pl);
|
||||||
Geom2dAdaptor_Curve::Load(PC,pf,pl);
|
if (PC)
|
||||||
|
{
|
||||||
|
Geom2dAdaptor_Curve::Load(PC,pf,pl);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
|
@ -442,8 +442,10 @@ static Standard_Boolean FindCoordBounds(const TopTools_SequenceOfShape& theFaces
|
|||||||
|
|
||||||
if (aPairSeq.Length() == 2)
|
if (aPairSeq.Length() == 2)
|
||||||
theMinCoord = aPairSeq(2).first - thePeriod;
|
theMinCoord = aPairSeq(2).first - thePeriod;
|
||||||
else
|
else if (aPairSeq.Length() > 0)
|
||||||
theMinCoord = aPairSeq(1).first;
|
theMinCoord = aPairSeq(1).first;
|
||||||
|
else
|
||||||
|
return Standard_False;
|
||||||
|
|
||||||
theMaxCoord = aPairSeq(1).second;
|
theMaxCoord = aPairSeq(1).second;
|
||||||
return Standard_True;
|
return Standard_True;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user