View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0033338 | Open CASCADE | OCCT:Coding | public | 2023-02-27 15:44 | 2023-07-06 12:46 |
| Reporter | DenisOrlov | Assigned To | dpasukhi | ||
| Priority | normal | Severity | tweak | ||
| Status | assigned | Resolution | open | ||
| Product Version | 7.7.0 | ||||
| Target Version | Unscheduled | ||||
| Summary | 0033338: Coding - IGESToBRep_CurveAndSurface's method has unreachable code | ||||
| Description | IGESToBRep_CurveAndSurface::TransferGeometry method has unreachable "else if" section: line 424 of the file IGESToBRep_CurveAndSurface.cxx : in case of start->IsKind(STANDARD_TYPE(IGESBasic_GroupWithoutBackP)) the code is stopped on the line 361, which works with most general case: start->IsKind(STANDARD_TYPE(IGESBasic_Group)). Moreover, both sections are equal, and should be merged into one. | ||||
| Steps To Reproduce | Not required | ||||
| Tags | No tags attached. | ||||
| Test case number | |||||
|
|
Branch CR33338 has been created by DenisOrlov. SHA-1: 5a0564a28e28f05143ba750a6dac2181d1d2e30f Detailed log of new commits: Author: dorlov Date: Tue Feb 28 14:11:06 2023 +0000 0033338: Coding - IGESToBRep_CurveAndSurface's method has unreachable code Fixed unreachable code in IGESToBRep_CurveAndSurface::TransferGeometry method |
|
|
Dear dpasukhi, please review: OCCT: CR33338 PROD: NO Most of builds are ok, http://jenkins-test-10.nnov.opencascade.com/view/CR33338-master-DenisOrlov/view/OCCT%20compile/ Tests relevant to the bug are passed. http://jenkins-test-10.nnov.opencascade.com/view/CR33338-master-DenisOrlov/view/COMPARE/ I Removed unreachable code. |
|
|
Please update style of msg definition And describe not discribed there
// Declaration of messages//
// DCE 22/12/98
//Message_Msg aMsg1005("IGES_1005"); // Software error : start IsNull.
//Message_Msg aMsg1015("IGES_1015"); // invalid type or exception raising (software error).
//Message_Msg aMsg1010("IGES_1010"); // Not sameparameter.
// Message_Msg aMsg1015("IGES_1015");
//Message_Msg aMsg210 ("XSTEP_210");
//Message_Msg aMsg202 ("XSTEP_202");
////////////////////////////
->>>> Removing dummy spaces
// Declaration of messages
// DCE 22/12/98
//Message_Msg aMsg1005("IGES_1005"); // Software error : start IsNull.
//Message_Msg aMsg1015("IGES_1015"); // invalid type or exception raising (software error).
//Message_Msg aMsg1010("IGES_1010"); // Not sameparameter.
//Message_Msg aMsg1015("IGES_1015");
//Message_Msg aMsg210 ("XSTEP_210");
//Message_Msg aMsg202 ("XSTEP_202");
////////////////////////////
Should be const
Standard_Integer anOnlyvisible = Interface_Static::IVal("read.iges.onlyvisible");
Moved spaces
OCC_CATCH_SIGNALS
aRes = TransferCurveAndSurface(theStart, theProgress);
...
try
{
OCC_CATCH_SIGNALS
aRes = TransferGeometry(aStsub, theProgress);
}
Shoudl be const value
Standard_Real aScunit = GetUnitFactor();
aVectr.Multiply(aScunit);
...
if (aSt408->HasScaleFactor())
{
Standard_Real aScalef = aSt408->ScaleFactor();
aT408.SetScaleFactor(aScalef);
}
Please remove dummy spaces } if(anOnlyvisible && aSt308->AssociatedEntity(anIndx)->BlankStatus() == 1 ) continue; Invalid checking IGESBasic_GroupWithoutBackP is a child of IGESBasic_Group
// 402 : Group Associativity
else if (theStart->IsKind(STANDARD_TYPE(IGESBasic_Group)) ||
theStart->IsKind(STANDARD_TYPE(IGESBasic_GroupWithoutBackP)))
{
Please save aNb of entities on the own const variable for (Standard_Integer anIndx=1; anIndx <= aSt402->NbEntities() && aPS.More(); anIndx++) |
|
|
Branch CR33338 has been updated forcibly by DenisOrlov. SHA-1: f501c6ffe20793edd06cbb82e130f8ae5a9439ed |
|
|
Branch CR33338_1 has been created by ichesnokova. SHA-1: 85d8da9c3c9b7ed7474227561990610f925cfede Detailed log of new commits: Author: dorlov Date: Tue Feb 28 14:11:06 2023 +0000 0033338: Coding - IGESToBRep_CurveAndSurface's method has unreachable code Fixed |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2023-02-27 15:44 | DenisOrlov | New Issue | |
| 2023-02-27 15:44 | DenisOrlov | Assigned To | => dpasukhi |
| 2023-02-27 16:13 | dpasukhi | Product Version | 7.7.1 => 7.7.0 |
| 2023-02-27 16:13 | dpasukhi | Target Version | 7.7.1 => 7.8.0 |
| 2023-02-27 16:15 | dpasukhi | Summary | IGESToBRep_CurveAndSurface::TransferGeometry method has unreachable "else if" section => Coding - IGESToBRep_CurveAndSurface's method has unreachable code |
| 2023-02-27 16:55 | dpasukhi | Severity | minor => tweak |
| 2023-02-27 17:46 | dpasukhi | Relationship added | related to 0023638 |
| 2023-02-28 15:21 | DenisOrlov | Assigned To | dpasukhi => DenisOrlov |
| 2023-02-28 17:11 | git | Note Added: 0113215 | |
| 2023-03-06 18:53 | ebelouso | Target Version | 7.8.0 => Unscheduled |
| 2023-03-16 17:35 | DenisOrlov | Assigned To | DenisOrlov => dpasukhi |
| 2023-03-16 17:35 | DenisOrlov | Status | new => resolved |
| 2023-03-16 17:35 | DenisOrlov | Steps to Reproduce Updated | |
| 2023-03-16 17:35 | DenisOrlov | Note Added: 0113289 | |
| 2023-03-21 23:03 | dpasukhi | Assigned To | dpasukhi => DenisOrlov |
| 2023-03-21 23:03 | dpasukhi | Status | resolved => assigned |
| 2023-03-21 23:03 | dpasukhi | Note Added: 0113311 | |
| 2023-03-27 17:40 | git | Note Added: 0113336 | |
| 2023-04-07 18:51 | dpasukhi | Assigned To | DenisOrlov => dpasukhi |
| 2023-07-06 12:46 | git | Note Added: 0113721 |