MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0030582Open CASCADE[OCCT] OCCT:Codingpublic2019-03-16 10:322019-04-08 12:18
Reporterkgv 
Assigned Toapn 
PrioritynormalSeverityminor 
StatusverifiedResolutionfixed 
PlatformOSOS Version
Product Version[OCCT] 7.3.0 
Target Version[OCCT] 7.4.0*Fixed in Version 
Summary0030582: Coding - avoid defining references to properties of NULL objects
DescriptionAlthough such references might be not actually accessed by checking other variables, it doesn't look fine passing to functions invalid references.
Steps To ReproduceN/A
TagsNo tags attached.
Test case numberNot needed
Attached Files

- Relationships
related to 0026042closedbugmaster Community OCCT won't work with the latest Xcode 
related to 0030565verifiedbugmaster Community Coding - Approx_SweepApproximation call on null pointer 
child of 0029181assignedapn Open CASCADE Jenkins Certification Tool - testing with enabled exceptions (undefined No_Exception) 

-  Notes
(0083010)
git (administrator)
2019-03-16 10:39

Branch CR30582 has been created by kgv.

SHA-1: 562cd1331f08416d9a5ddb4a4f12f4451ef65218


Detailed log of new commits:

Author: kgv
Date: Fri Mar 15 18:06:04 2019 +0300

    0030582: Coding - avoid defining references to properties of NULL objects
    
    Approx_SweepApproximation::Perform() now creates empty arrays.
    GeomAdaptor_SurfaceOfRevolution::UTrim() - fixed No_Exception misuse.
    Poly_Triangulation::UVNodes() has been extended with NULL check.
(0083011)
kgv (developer)
2019-03-16 10:40

Patch is ready for review.
(0083017)
git (administrator)
2019-03-16 15:19

Branch CR30582 has been updated by kgv.

SHA-1: d8cace4b03fbd11e338e390924b84ce45570477f


Detailed log of new commits:

Author: kgv
Date: Sat Mar 16 15:12:51 2019 +0300

    # 0030582 BSplCLib::MovePoint()
    
    BSplCLib::MovePoint() and BSplCLib::MovePointAndTangent() now take optional
    weights parameter as pointer consistent to other methods like BSplCLib::BuildEval().

(0083061)
git (administrator)
2019-03-18 22:12

Branch CR30582_1 has been created by kgv.

SHA-1: 576ba89c89dd8068aa9721abf316ccc204a9d89d


Detailed log of new commits:

Author: kgv
Date: Fri Mar 15 18:06:04 2019 +0300

    0030582: Coding - avoid defining references to properties of NULL objects
    
    Approx_SweepApproximation::Perform() now creates empty arrays.
    GeomAdaptor_SurfaceOfRevolution::UTrim() - fixed No_Exception misuse.
    Poly_Triangulation::UVNodes() has been extended with NULL check.
    
    BSplCLib::MovePoint() and BSplCLib::MovePointAndTangent() now take optional
    weights parameter as pointer consistent to other methods like BSplCLib::BuildEval().
(0083153)
msv (developer)
2019-03-20 18:39
edited on: 2019-03-20 18:39

src/BSplCLib/BSplCLib.hxx
- Descriptions of methods mentions parameter Rational that is removed. Please update descriptions.

src/Geom2d/Geom2d_BSplineCurve_1.cxx
- Please everywhere in your changes, eliminate tab characters to avoid defect of indentation when tab size setting is equal to 8.

src/Poly/Poly_Triangulation.hxx
- What is the reason to return empty static array in UVNodes() method if HasUVNodes() method can be used to check this condition?

Please perform testing of the patch.

(0083158)
git (administrator)
2019-03-20 22:02

Branch CR30582_1 has been updated by kgv.

SHA-1: 8fce7cbab9ed37d2b40b0e8d8da68217042689d0


Detailed log of new commits:

Author: kgv
Date: Wed Mar 20 21:57:00 2019 +0300

    # remarks

(0083159)
git (administrator)
2019-03-20 22:13

Branch CR30582_2 has been created by kgv.

SHA-1: 8c36d8b8d5f9540cb801a518287e8091dde4c965


Detailed log of new commits:

Author: kgv
Date: Fri Mar 15 18:06:04 2019 +0300

    0030582: Coding - avoid defining references to properties of NULL objects
    
    Approx_SweepApproximation::Perform() now creates empty arrays.
    GeomAdaptor_SurfaceOfRevolution::UTrim() - fixed No_Exception misuse.
    StdPrs_ShadedShape - fixed defining an invalid reference to Poly_Triangulation::UVNodes().
    
    BSplCLib::MovePoint() and BSplCLib::MovePointAndTangent() now take optional
    weights parameter as pointer consistent to other methods like BSplCLib::BuildEval().
(0083161)
git (administrator)
2019-03-20 22:36

Branch CR30582_2 has been updated forcibly by kgv.

SHA-1: a9d640a48261bfc54f349d1201c62faf9c9a6cf0
(0083163)
kgv (developer)
2019-03-21 07:03

Remarks have been applied:

http://jenkins-test-12.nnov.opencascade.com:8080/view/CR30582_2-master-KGV/ [^]
(0083171)
msv (developer)
2019-03-21 09:28

Remark about tabs in Geom2d_BSplineCurve_1.cxx has not been considered.
(0083172)
git (administrator)
2019-03-21 09:42

Branch CR30582_2 has been updated forcibly by kgv.

SHA-1: f268c991bf0fa853aa7c685b1b6cb6ec57bd690e
(0083173)
git (administrator)
2019-03-21 09:44

Branch CR30582_2 has been updated forcibly by kgv.

SHA-1: 5fc689e0c8fae588df6d71eb6f9fc3dedf678189
(0083177)
kgv (developer)
2019-03-21 10:40

Tabs removed from Geom2d_BSplineCurve_1.cxx (in addition to Geom_BSplineCurve_1.cxx)
(0083178)
msv (developer)
2019-03-21 10:50

Reviewed.
(0083184)
apn (administrator)
2019-03-21 13:03

Combination -
OCCT branch : CR30582_2
master SHA - f268c991bf0fa853aa7c685b1b6cb6ec57bd690e
d67d4b811012eef8913d3c535c29654d0acf3c4c
Products branch : master SHA - b3958866f73826c2eaaa9470209980d22e210fba
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 16618.880000000074 / 16593.449999999997 [+0.15%]
Products
Total CPU difference: 9114.300000000032 / 9102.210000000046 [+0.13%]
Windows-64-VC14:
OCCT
Total CPU difference: 18083.15625 / 17984.46875 [+0.55%]
Products
Total CPU difference: 10560.984375 / 10609.28125 [-0.46%]

Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0083489)
git (administrator)
2019-04-08 12:18

Branch CR30582_2 has been deleted by inv.

SHA-1: 5fc689e0c8fae588df6d71eb6f9fc3dedf678189
(0083492)
git (administrator)
2019-04-08 12:18

Branch CR30582_1 has been deleted by inv.

SHA-1: 8fce7cbab9ed37d2b40b0e8d8da68217042689d0
(0083502)
git (administrator)
2019-04-08 12:18

Branch CR30582 has been deleted by inv.

SHA-1: d8cace4b03fbd11e338e390924b84ce45570477f

- Related Changesets
occt: master aff73fd5
Timestamp: 2019-03-15 15:06:04
Author: kgv
Committer: apn
Details ] Diff ]
0030582: Coding - avoid defining references to properties of NULL objects

Approx_SweepApproximation::Perform() now creates empty arrays.
GeomAdaptor_SurfaceOfRevolution::UTrim() - fixed No_Exception misuse.
StdPrs_ShadedShape - fixed defining an invalid reference to Poly_Triangulation::UVNodes().

BSplCLib::MovePoint() and BSplCLib::MovePointAndTangent() now take optional
weights parameter as pointer consistent to other methods like BSplCLib::BuildEval().
mod - src/Approx/Approx_SweepApproximation.cxx Diff ] File ]
mod - src/BSplCLib/BSplCLib.hxx Diff ] File ]
mod - src/BSplCLib/BSplCLib_2.cxx Diff ] File ]
mod - src/BSplCLib/BSplCLib_CurveComputation.gxx Diff ] File ]
mod - src/Geom/Geom_BSplineCurve.cxx Diff ] File ]
mod - src/Geom/Geom_BSplineCurve_1.cxx Diff ] File ]
mod - src/Geom2d/Geom2d_BSplineCurve.cxx Diff ] File ]
mod - src/Geom2d/Geom2d_BSplineCurve_1.cxx Diff ] File ]
mod - src/GeomAdaptor/GeomAdaptor_SurfaceOfRevolution.cxx Diff ] File ]
mod - src/Law/Law_BSpline.cxx Diff ] File ]
mod - src/NCollection/NCollection_DefineHArray1.hxx Diff ] File ]
mod - src/StdPrs/StdPrs_ShadedShape.cxx Diff ] File ]

- Issue History
Date Modified Username Field Change
2019-03-16 10:32 kgv New Issue
2019-03-16 10:32 kgv Assigned To => kgv
2019-03-16 10:39 git Note Added: 0083010
2019-03-16 10:40 kgv Relationship added child of 0029181
2019-03-16 10:40 kgv Note Added: 0083011
2019-03-16 10:40 kgv Assigned To kgv => abv
2019-03-16 10:40 kgv Status new => resolved
2019-03-16 15:19 git Note Added: 0083017
2019-03-16 17:52 kgv Relationship added related to 0026042
2019-03-18 22:12 git Note Added: 0083061
2019-03-18 22:12 kgv Assigned To abv => msv
2019-03-20 18:39 msv Note Added: 0083153
2019-03-20 18:39 msv Assigned To msv => kgv
2019-03-20 18:39 msv Status resolved => assigned
2019-03-20 18:39 msv Note Edited: 0083153 View Revisions
2019-03-20 22:02 git Note Added: 0083158
2019-03-20 22:13 git Note Added: 0083159
2019-03-20 22:36 git Note Added: 0083161
2019-03-21 07:03 kgv Note Added: 0083163
2019-03-21 07:03 kgv Assigned To kgv => msv
2019-03-21 07:03 kgv Status assigned => resolved
2019-03-21 09:28 msv Note Added: 0083171
2019-03-21 09:29 msv Assigned To msv => kgv
2019-03-21 09:29 msv Status resolved => assigned
2019-03-21 09:42 git Note Added: 0083172
2019-03-21 09:44 git Note Added: 0083173
2019-03-21 10:40 kgv Note Added: 0083177
2019-03-21 10:40 kgv Assigned To kgv => msv
2019-03-21 10:40 kgv Status assigned => resolved
2019-03-21 10:50 msv Note Added: 0083178
2019-03-21 10:50 msv Assigned To msv => bugmaster
2019-03-21 10:50 msv Status resolved => reviewed
2019-03-21 13:03 apn Test case number => Not needed
2019-03-21 13:03 apn Note Added: 0083184
2019-03-21 13:03 apn Status reviewed => tested
2019-03-24 18:54 apn Changeset attached => occt master aff73fd5
2019-03-24 18:54 apn Assigned To bugmaster => apn
2019-03-24 18:54 apn Status tested => verified
2019-03-24 18:54 apn Resolution open => fixed
2019-03-25 14:21 kgv Relationship added related to 0030565
2019-04-08 12:18 git Note Added: 0083489
2019-04-08 12:18 git Note Added: 0083492
2019-04-08 12:18 git Note Added: 0083502


Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker