]> OCCT Git - occt.git/commitdiff
0027643: Coding rules - eliminate GCC warning -Wmaybe-uninitialized
authorkgv <kgv@opencascade.com>
Sun, 26 Jun 2016 17:10:35 +0000 (20:10 +0300)
committerbugmaster <bugmaster@opencascade.com>
Fri, 1 Jul 2016 09:28:34 +0000 (12:28 +0300)
src/GCPnts/GCPnts_AbscissaPoint.pxx
src/GeomFill/GeomFill_SectionPlacement.cxx

index 5cba7bb1545cef512c3c27316e6321cd602b6459..cce1214e1b1c5968a37eae9782a17de8c478deff 100644 (file)
@@ -167,7 +167,7 @@ static void AdvCompute(CPnts_AbscissaPoint& theComputer,
                    Standard_Real& Ui,
                    const Standard_Real EPSILON) 
 {
-  Standard_Real Ratio;
+  Standard_Real Ratio = 1.0;
   GCPnts_AbscissaType Type = computeType(C,Ratio);
 
   switch (Type) {
@@ -312,7 +312,7 @@ Standard_Real GCPnts_AbscissaPoint::Length(const TheCurve& C,
                                           const Standard_Real U1,
                                           const Standard_Real U2)
 {
-  Standard_Real Ratio;
+  Standard_Real Ratio = 1.0;
   GCPnts_AbscissaType Type = computeType(C,Ratio);
   switch (Type) {
 
@@ -353,7 +353,7 @@ Standard_Real GCPnts_AbscissaPoint::Length(const TheCurve& C,
                                           const Standard_Real U2,
                                           const Standard_Real Tol)
 {
-  Standard_Real Ratio;
+  Standard_Real Ratio = 1.0;
   GCPnts_AbscissaType Type = computeType(C,Ratio);
   switch (Type) {
 
index 0af4b9919ed6b1c22d8aa6a5f8817b52541566fc..e149490d4bad1a23e3255d106548e3a73302bbaa 100644 (file)
@@ -412,7 +412,7 @@ void GeomFill_SectionPlacement::Perform(const Handle(Adaptor3d_HCurve)& Path,
       PathParam = Path->FirstParameter();
       SecParam =  myAdpSection.FirstParameter();
       
-      Standard_Real distaux, taux, alpha;
+      Standard_Real distaux, taux = 0.0, alpha;
       gp_Pnt PonPath, PonSec, P;
       gp_Vec VRef, dp1;
       VRef.SetXYZ(TheAxe.Direction().XYZ());