1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-10 18:51:21 +03:00

0024495: Crash during performeng boolean operation on attached shape for Windows VC2010 64 bit

Recursion in the method Path in BOPAlgo_WireSplitter has been replaced with cycle.
This commit is contained in:
emv 2013-12-25 15:14:54 +04:00 committed by bugmaster
parent 6a866b3268
commit b7357c8b55

View File

@ -326,9 +326,9 @@ static
//======================================================================= //=======================================================================
void Path (const GeomAdaptor_Surface& aGAS, void Path (const GeomAdaptor_Surface& aGAS,
const TopoDS_Face& myFace, const TopoDS_Face& myFace,
const TopoDS_Vertex& aVa, const TopoDS_Vertex& aVFirst,
const TopoDS_Edge& aEOuta, const TopoDS_Edge& aEFirst,
BOPAlgo_EdgeInfo& anEdgeInfo, BOPAlgo_EdgeInfo& aEIFirst,
BOPCol_SequenceOfShape& aLS, BOPCol_SequenceOfShape& aLS,
BOPCol_SequenceOfShape& aVertVa, BOPCol_SequenceOfShape& aVertVa,
BOPCol_SequenceOfPnt2d& aCoordVa, BOPCol_SequenceOfPnt2d& aCoordVa,
@ -341,15 +341,20 @@ void Path (const GeomAdaptor_Surface& aGAS,
Standard_Real aTol2D, aTol2D2; Standard_Real aTol2D, aTol2D2;
Standard_Real aTol2, aD2, aTwoPI; Standard_Real aTol2, aD2, aTwoPI;
Standard_Boolean anIsSameV2d, anIsSameV, anIsFound, anIsOut, anIsNotPassed; Standard_Boolean anIsSameV2d, anIsSameV, anIsFound, anIsOut, anIsNotPassed;
TopoDS_Vertex aVb; TopoDS_Vertex aVa, aVb;
TopoDS_Edge aEOutb; TopoDS_Edge aEOuta;
BOPAlgo_ListIteratorOfListOfEdgeInfo anIt; BOPAlgo_ListIteratorOfListOfEdgeInfo anIt;
// //
aVa = aVFirst;
aEOuta = aEFirst;
BOPAlgo_EdgeInfo* anEdgeInfo = &aEIFirst;
//
aTwoPI = M_PI + M_PI; aTwoPI = M_PI + M_PI;
aTol=1.e-7; aTol=1.e-7;
// //
// append block // append block
// //
for (;;) {
// Do not escape through edge from which you enter // Do not escape through edge from which you enter
aNb=aLS.Length(); aNb=aLS.Length();
if (aNb==1) { if (aNb==1) {
@ -359,7 +364,7 @@ void Path (const GeomAdaptor_Surface& aGAS,
} }
} }
// //
anEdgeInfo.SetPassed(Standard_True); anEdgeInfo->SetPassed(Standard_True);
aLS.Append(aEOuta); aLS.Append(aEOuta);
aVertVa.Append(aVa); aVertVa.Append(aVa);
@ -515,7 +520,7 @@ void Path (const GeomAdaptor_Surface& aGAS,
// //
if (!iCnt) { if (!iCnt) {
// no way to go . (Error) // no way to go . (Error)
return ; return;
} }
// //
if (iCnt==1) { if (iCnt==1) {
@ -560,11 +565,11 @@ void Path (const GeomAdaptor_Surface& aGAS,
// no way to go . (Error) // no way to go . (Error)
return; return;
} }
aEOutb=pEdgeInfo->Edge();
// //
Path (aGAS, myFace, aVb, aEOutb, *pEdgeInfo, aLS, aVa = aVb;
aVertVa, aCoordVa, aCB, mySmartMap); aEOuta = pEdgeInfo->Edge();
anEdgeInfo = pEdgeInfo;
}
} }
//======================================================================= //=======================================================================
// function: ClockWiseAngle // function: ClockWiseAngle