1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-02 17:46:22 +03:00

0031821: Coding - Uninitialized variables in TKFillet project

Some variables that remain uninitialized in the project TKFillet received proper initializers.
This commit is contained in:
tiv 2020-10-05 09:52:31 +03:00 committed by bugmaster
parent 809a2e13f8
commit 50ae6dad80
12 changed files with 111 additions and 37 deletions

View File

@ -50,6 +50,7 @@ BlendFunc_CSConstRad::BlendFunc_CSConstRad(const Handle(Adaptor3d_HSurface)& S,
maxang(RealFirst()), minang(RealLast()),
mySShape(BlendFunc_Rational)
{
myTConv = Convert_TgtThetaOver2;
}

View File

@ -68,6 +68,7 @@ BlendFunc_ConstRad::BlendFunc_ConstRad(const Handle(Adaptor3d_HSurface)& S1,
xval.Init(-9.876e100);
myXOrder = -1;
myTOrder = -1;
myTConv = Convert_TgtThetaOver2;
}
//=======================================================================

View File

@ -70,7 +70,7 @@ static Standard_Boolean IsLineOrCircle(const TopoDS_Edge& E,
//purpose :
//=======================================================================
ChFi2d_Builder::ChFi2d_Builder()
ChFi2d_Builder::ChFi2d_Builder() : status (ChFi2d_NotPlanar)
{
}

View File

@ -26,12 +26,20 @@ IMPLEMENT_STANDARD_RTTIEXT(ChFiDS_ChamfSpine,ChFiDS_Spine)
//purpose :
//=======================================================================
ChFiDS_ChamfSpine::ChFiDS_ChamfSpine()
: d1 (0.0),
d2 (0.0),
angle (0.0),
mChamf (ChFiDS_Sym)
{
myMode = ChFiDS_ClassicChamfer;
}
ChFiDS_ChamfSpine::ChFiDS_ChamfSpine(const Standard_Real Tol):
ChFiDS_Spine(Tol)
ChFiDS_ChamfSpine::ChFiDS_ChamfSpine(const Standard_Real Tol)
: ChFiDS_Spine (Tol),
d1 (0.0),
d2 (0.0),
angle (0.0),
mChamf (ChFiDS_Sym)
{
myMode = ChFiDS_ClassicChamfer;
}

View File

@ -23,7 +23,11 @@
//function : ChFiDS_CircSection
//purpose :
//=======================================================================
ChFiDS_CircSection::ChFiDS_CircSection(){}
ChFiDS_CircSection::ChFiDS_CircSection()
: myF (0.0),
myL (0.0)
{
}
//=======================================================================

View File

@ -39,10 +39,14 @@
//function : ChFiDS_ElSpine
//purpose :
//=======================================================================
ChFiDS_ElSpine::ChFiDS_ElSpine():periodic(0)
ChFiDS_ElSpine::ChFiDS_ElSpine()
: pfirst (0.0),
plast (0.0),
period (0.0),
periodic (Standard_False),
pfirstsav (Precision::Infinite()),
plastsav (Precision::Infinite())
{
pfirstsav = Precision::Infinite();
plastsav = Precision::Infinite();
}

View File

@ -23,6 +23,10 @@
//purpose :
//=======================================================================
ChFiDS_FaceInterference::ChFiDS_FaceInterference()
: firstParam (0.0),
lastParam (0.0),
lineindex (0),
LineTransition (TopAbs_FORWARD)
{
}

View File

@ -22,6 +22,9 @@
//purpose :
//=======================================================================
ChFiDS_Regul::ChFiDS_Regul()
: icurv (0),
is1 (0),
is2 (0)
{
}

View File

@ -41,16 +41,26 @@ IMPLEMENT_STANDARD_RTTIEXT(ChFiDS_Spine,Standard_Transient)
//purpose :
//=======================================================================
ChFiDS_Spine::ChFiDS_Spine()
: splitdone(Standard_False),
myMode(ChFiDS_ClassicChamfer),
tolesp(Precision::Confusion()),
firstprolon(Standard_False),
lastprolon(Standard_False),
firstistgt(Standard_False),
lastistgt(Standard_False),
hasfirsttgt(Standard_False),
haslasttgt(Standard_False),
hasref(Standard_False)
: splitdone (Standard_False),
myMode (ChFiDS_ClassicChamfer),
indexofcurve (0),
myTypeOfConcavity (ChFiDS_Other),
firstState (ChFiDS_OnSame),
lastState (ChFiDS_OnSame),
tolesp (Precision::Confusion()),
firstparam (0.0),
lastparam (0.0),
firstprolon (Standard_False),
lastprolon (Standard_False),
firstistgt (Standard_False),
lastistgt (Standard_False),
firsttgtpar (0.0),
lasttgtpar (0.0),
hasfirsttgt (Standard_False),
haslasttgt (Standard_False),
valref (0.0),
hasref (Standard_False),
errorstate (ChFiDS_Ok)
{
}
@ -59,16 +69,26 @@ ChFiDS_Spine::ChFiDS_Spine()
//purpose :
//=======================================================================
ChFiDS_Spine::ChFiDS_Spine(const Standard_Real Tol)
: splitdone(Standard_False),
myMode(ChFiDS_ClassicChamfer),
tolesp(Tol),
firstprolon(Standard_False),
lastprolon(Standard_False),
firstistgt(Standard_False),
lastistgt(Standard_False),
hasfirsttgt(Standard_False),
haslasttgt(Standard_False),
hasref(Standard_False)
: splitdone (Standard_False),
myMode (ChFiDS_ClassicChamfer),
indexofcurve (0),
myTypeOfConcavity (ChFiDS_Other),
firstState (ChFiDS_OnSame),
lastState (ChFiDS_OnSame),
tolesp (Tol),
firstparam (0.0),
lastparam (0.0),
firstprolon (Standard_False),
lastprolon (Standard_False),
firstistgt (Standard_False),
lastistgt (Standard_False),
firsttgtpar (0.0),
lasttgtpar (0.0),
hasfirsttgt (Standard_False),
haslasttgt (Standard_False),
valref (0.0),
hasref (Standard_False),
errorstate (ChFiDS_Ok)
{
}

View File

@ -22,12 +22,27 @@
IMPLEMENT_STANDARD_RTTIEXT(ChFiDS_Stripe,Standard_Transient)
ChFiDS_Stripe::ChFiDS_Stripe ():
begfilled(/*Standard_False*/0), // eap, Apr 29 2002, occ293
endfilled(/*Standard_False*/0),
orcurv1(TopAbs_FORWARD),
orcurv2(TopAbs_FORWARD)
{}
ChFiDS_Stripe::ChFiDS_Stripe ()
: pardeb1 (0.0),
parfin1 (0.0),
pardeb2 (0.0),
parfin2 (0.0),
myChoix (0),
indexOfSolid (0),
indexOfcurve1 (0),
indexOfcurve2 (0),
indexfirstPOnS1 (0),
indexlastPOnS1 (0),
indexfirstPOnS2 (0),
indexlastPOnS2 (0),
begfilled(/*Standard_False*/0), // eap, Apr 29 2002, occ293
endfilled(/*Standard_False*/0),
myOr1 (TopAbs_FORWARD),
myOr2 (TopAbs_FORWARD),
orcurv1 (TopAbs_FORWARD),
orcurv2 (TopAbs_FORWARD)
{
}
void ChFiDS_Stripe::Reset()
{

View File

@ -24,10 +24,23 @@
IMPLEMENT_STANDARD_RTTIEXT(ChFiDS_SurfData,Standard_Transient)
ChFiDS_SurfData::ChFiDS_SurfData () :
indexOfS1(0),indexOfS2(0),indexOfConge(0),
isoncurv1(0),isoncurv2(0),twistons1(0),twistons2(0)
{}
ChFiDS_SurfData::ChFiDS_SurfData()
: ufspine (0.0),
ulspine (0.0),
myfirstextend (0.0),
mylastextend (0.0),
indexOfS1 (0),
indexOfC1 (0),
indexOfS2 (0),
indexOfC2 (0),
indexOfConge (0),
isoncurv1 (Standard_False),
isoncurv2 (Standard_False),
twistons1 (Standard_False),
twistons2 (Standard_False),
orientation (TopAbs_FORWARD)
{
}
//=======================================================================
//function : Copy

View File

@ -41,6 +41,7 @@ FilletSurf_Builder::FilletSurf_Builder(const TopoDS_Shape& S,
myIntBuild(S,ChFi3d_Polynomial,Ta,Tapp3d,Tapp2d)
{
myisdone=FilletSurf_IsOk;
myerrorstatus = FilletSurf_EmptyList;
int add =myIntBuild.Add(E,R);
if (add!=0) {
myisdone=FilletSurf_IsNotOk;